summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorErik Andrén <erik.andren@gmail.com>2009-05-03 20:51:36 +0200
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-06-16 23:20:53 +0200
commit17720e07b6ac573c8929c39f9036dbc460867b72 (patch)
tree0a53efb6986017bf828ff7075d98d6735b77414d /drivers
parentV4L/DVB (11694): gspca - stv06xx-vv6410: No need to double set gain and exposure (diff)
downloadlinux-17720e07b6ac573c8929c39f9036dbc460867b72.tar.xz
linux-17720e07b6ac573c8929c39f9036dbc460867b72.zip
V4L/DVB (11695): gspca - stv06xx-vv6410: Set analog gain at init
Set the analog gain at sensor init. Also set a sensible default value. Signed-off-by: Erik Andrén <erik.andren@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/video/gspca/stv06xx/stv06xx_vv6410.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/media/video/gspca/stv06xx/stv06xx_vv6410.c b/drivers/media/video/gspca/stv06xx/stv06xx_vv6410.c
index f6603a9deab8..11a0c002f5dc 100644
--- a/drivers/media/video/gspca/stv06xx/stv06xx_vv6410.c
+++ b/drivers/media/video/gspca/stv06xx/stv06xx_vv6410.c
@@ -80,7 +80,7 @@ static const struct ctrl vv6410_ctrl[] = {
.minimum = 0,
.maximum = 15,
.step = 1,
- .default_value = 0
+ .default_value = 10
},
.set = vv6410_set_analog_gain,
.get = vv6410_get_analog_gain
@@ -162,6 +162,11 @@ static int vv6410_init(struct sd *sd)
err = vv6410_set_exposure(&sd->gspca_dev,
sensor_settings[EXPOSURE_IDX]);
+ if (err < 0)
+ return err;
+
+ err = vv6410_set_analog_gain(&sd->gspca_dev,
+ sensor_settings[GAIN_IDX]);
return (err < 0) ? err : 0;
}