V4L/DVB: gspca - sn9c20x: Bad transfer size of Bayer images
authorJean-François Moine <moinejf@free.fr>
Mon, 13 Sep 2010 08:22:37 +0000 (05:22 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 28 Sep 2010 01:22:01 +0000 (22:22 -0300)
As the end of frame marker does not contain any pixel, it must not be
transferred.

Reported-by: Ivo Jager <ivo.jager@siliconfields.net>
Signed-off-by: Jean-François Moine <moinejf@free.fr>
Cc: stable@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/gspca/sn9c20x.c

index 83a718f..9052d57 100644 (file)
@@ -2357,8 +2357,7 @@ static void sd_pkt_scan(struct gspca_dev *gspca_dev,
                            (data[33] << 10);
                avg_lum >>= 9;
                atomic_set(&sd->avg_lum, avg_lum);
-               gspca_frame_add(gspca_dev, LAST_PACKET,
-                               data, len);
+               gspca_frame_add(gspca_dev, LAST_PACKET, NULL, 0);
                return;
        }
        if (gspca_dev->last_packet_type == LAST_PACKET) {