diff options
author | Jean-Francois Moine <moinejf@free.fr> | 2009-11-13 07:21:03 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-12-05 15:41:59 -0500 |
commit | 76dd272b56cd1c7fa013ef5d7eb28c4d319e322b (patch) | |
tree | 4cd4660a847d2c1fdd9104ce4cff92b647e09b15 /drivers/media/video/gspca/vc032x.c | |
parent | d131c3c9e136cb5a817094c3dc4b7261b495cd6e (diff) |
V4L/DVB (13453): gspca - all subdrivers: Remove the unused frame ptr from pkt_scan().
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/gspca/vc032x.c')
-rw-r--r-- | drivers/media/video/gspca/vc032x.c | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/drivers/media/video/gspca/vc032x.c b/drivers/media/video/gspca/vc032x.c index 589042f6adbe..26675236fbd2 100644 --- a/drivers/media/video/gspca/vc032x.c +++ b/drivers/media/video/gspca/vc032x.c | |||
@@ -2987,7 +2987,6 @@ static void sd_stop0(struct gspca_dev *gspca_dev) | |||
2987 | } | 2987 | } |
2988 | 2988 | ||
2989 | static void sd_pkt_scan(struct gspca_dev *gspca_dev, | 2989 | static void sd_pkt_scan(struct gspca_dev *gspca_dev, |
2990 | struct gspca_frame *frame, /* target */ | ||
2991 | u8 *data, /* isoc packet */ | 2990 | u8 *data, /* isoc packet */ |
2992 | int len) /* iso pkt length */ | 2991 | int len) /* iso pkt length */ |
2993 | { | 2992 | { |
@@ -2996,21 +2995,25 @@ static void sd_pkt_scan(struct gspca_dev *gspca_dev, | |||
2996 | if (data[0] == 0xff && data[1] == 0xd8) { | 2995 | if (data[0] == 0xff && data[1] == 0xd8) { |
2997 | PDEBUG(D_PACK, | 2996 | PDEBUG(D_PACK, |
2998 | "vc032x header packet found len %d", len); | 2997 | "vc032x header packet found len %d", len); |
2999 | frame = gspca_frame_add(gspca_dev, LAST_PACKET, frame, | 2998 | gspca_frame_add(gspca_dev, LAST_PACKET, NULL, 0); |
3000 | data, 0); | ||
3001 | data += sd->image_offset; | 2999 | data += sd->image_offset; |
3002 | len -= sd->image_offset; | 3000 | len -= sd->image_offset; |
3003 | gspca_frame_add(gspca_dev, FIRST_PACKET, frame, | 3001 | gspca_frame_add(gspca_dev, FIRST_PACKET, data, len); |
3004 | data, len); | ||
3005 | return; | 3002 | return; |
3006 | } | 3003 | } |
3007 | 3004 | ||
3008 | /* The vc0321 sends some additional data after sending the complete | 3005 | /* The vc0321 sends some additional data after sending the complete |
3009 | * frame, we ignore this. */ | 3006 | * frame, we ignore this. */ |
3010 | if (sd->bridge == BRIDGE_VC0321 | 3007 | if (sd->bridge == BRIDGE_VC0321) { |
3011 | && len > frame->v4l2_buf.length - (frame->data_end - frame->data)) | 3008 | struct gspca_frame *frame; |
3012 | len = frame->v4l2_buf.length - (frame->data_end - frame->data); | 3009 | int l; |
3013 | gspca_frame_add(gspca_dev, INTER_PACKET, frame, data, len); | 3010 | |
3011 | frame = gspca_get_i_frame(gspca_dev); | ||
3012 | l = frame->data_end - frame->data; | ||
3013 | if (len > frame->v4l2_buf.length - l) | ||
3014 | len = frame->v4l2_buf.length - l; | ||
3015 | } | ||
3016 | gspca_frame_add(gspca_dev, INTER_PACKET, data, len); | ||
3014 | } | 3017 | } |
3015 | 3018 | ||
3016 | static int sd_sethflip(struct gspca_dev *gspca_dev, __s32 val) | 3019 | static int sd_sethflip(struct gspca_dev *gspca_dev, __s32 val) |