media: gspca: Limit frame size to sizeimage.
authorChad Fraleigh <chadf@triularity.org>
Sun, 29 Aug 2021 23:51:27 +0000 (01:51 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 30 Sep 2021 08:07:56 +0000 (10:07 +0200)
commit936c7daa4d99c0c5d10c97cb9afc28966d547d80
tree0e19efc98b92ffdf4655877e03a9bfbc3225fcb6
parentb94b551050b2aad898f87cb78c5e84d3e3e049f2
media: gspca: Limit frame size to sizeimage.

Limit frame size to what userland code expects. This can happen when
cameras, such as Kensington VideoCAM, use fixed sized transfer packets
which includes trailing junk in the final packet.

Signed-off-by: Chad Fraleigh <chadf@triularity.org>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/usb/gspca/gspca.c