aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/usb/gspca
diff options
context:
space:
mode:
authorJean-François Moine <moinejf@free.fr>2012-11-22 06:59:06 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-12-21 09:40:20 -0500
commit04881127340c43fc5b8dbc2c381c1928ee22559e (patch)
tree0b52c7e85eecb73663e4638017e3e38f223b7e90 /drivers/media/usb/gspca
parent1c9f5bd7cb8a74965e7a19eead5d77c35bf30db7 (diff)
[media] gspca - stv06xx: Fix a regression with the bridge/sensor vv6410
Setting the H and V flip controls at webcam connection time prevents the webcam to work correctly. This patch checks if the webcam is streaming before setting the flips. It does not set the flips (nor other controls) at webcam start time. Tested-by: Philippe ROUBACH <philippe.roubach@free.fr> Signed-off-by: Jean-François Moine <moinejf@free.fr> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/usb/gspca')
-rw-r--r--drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c b/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
index 748e1421d6d8..cbb153180d59 100644
--- a/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
+++ b/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
@@ -52,9 +52,13 @@ static int vv6410_s_ctrl(struct v4l2_ctrl *ctrl)
52 52
53 switch (ctrl->id) { 53 switch (ctrl->id) {
54 case V4L2_CID_HFLIP: 54 case V4L2_CID_HFLIP:
55 if (!gspca_dev->streaming)
56 return 0;
55 err = vv6410_set_hflip(gspca_dev, ctrl->val); 57 err = vv6410_set_hflip(gspca_dev, ctrl->val);
56 break; 58 break;
57 case V4L2_CID_VFLIP: 59 case V4L2_CID_VFLIP:
60 if (!gspca_dev->streaming)
61 return 0;
58 err = vv6410_set_vflip(gspca_dev, ctrl->val); 62 err = vv6410_set_vflip(gspca_dev, ctrl->val);
59 break; 63 break;
60 case V4L2_CID_GAIN: 64 case V4L2_CID_GAIN: