summaryrefslogtreecommitdiffstats
path: root/drivers/media/usb/gspca/ov534.c
diff options
context:
space:
mode:
authorOndrej Zary2013-08-30 22:54:23 +0200
committerMauro Carvalho Chehab2013-09-26 12:19:09 +0200
commit1966bc2a48f12d5d11c4fbe0880955cc4bfda0f9 (patch)
tree6a1c4e50b81e194b1d60f0e62fd566f662b3657a /drivers/media/usb/gspca/ov534.c
parent[media] Add HCL T12Rg-H to STK webcam upside-down table (diff)
downloadkernel-qcow2-linux-1966bc2a48f12d5d11c4fbe0880955cc4bfda0f9.tar.gz
kernel-qcow2-linux-1966bc2a48f12d5d11c4fbe0880955cc4bfda0f9.tar.xz
kernel-qcow2-linux-1966bc2a48f12d5d11c4fbe0880955cc4bfda0f9.zip
[media] gspca: store current mode instead of individual parameters
Store complete current mode (struct v4l2_pix_format) in struct gspca_dev instead of separate pixfmt, width and height parameters. This is a preparation for variable resolution support. Signed-off-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/usb/gspca/ov534.c')
-rw-r--r--drivers/media/usb/gspca/ov534.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/usb/gspca/ov534.c b/drivers/media/usb/gspca/ov534.c
index 03a33c46ca2c..90f0d637cd9d 100644
--- a/drivers/media/usb/gspca/ov534.c
+++ b/drivers/media/usb/gspca/ov534.c
@@ -1440,9 +1440,10 @@ static void sd_pkt_scan(struct gspca_dev *gspca_dev,
/* If this packet is marked as EOF, end the frame */
} else if (data[1] & UVC_STREAM_EOF) {
sd->last_pts = 0;
- if (gspca_dev->pixfmt == V4L2_PIX_FMT_YUYV
+ if (gspca_dev->pixfmt.pixelformat == V4L2_PIX_FMT_YUYV
&& gspca_dev->image_len + len - 12 !=
- gspca_dev->width * gspca_dev->height * 2) {
+ gspca_dev->pixfmt.width *
+ gspca_dev->pixfmt.height * 2) {
PDEBUG(D_PACK, "wrong sized frame");
goto discard;
}