media: v4l2-compat-ioctl32: prevent go past max size

commit ea72fbf588 upstream.

As warned by smatch:
	drivers/media/v4l2-core/v4l2-compat-ioctl32.c:879 put_v4l2_ext_controls32() warn: check for integer overflow 'count'

The access_ok() logic should check for too big arrays too.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
This commit is contained in:
Mauro Carvalho Chehab 2018-04-11 11:47:32 -04:00 • committed by Ben Hutchings
commit f12d67fe8c