aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/gspca
diff options
context:
space:
mode:
authorBrian Johnson <brijohn@gmail.com>2009-09-03 18:07:13 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-09-12 11:20:14 -0400
commit13a84fa4de7c050b27f14d39720f8b036cecde24 (patch)
tree3a0bf9eb313c00d0cfa9cabecee426b9940fee95 /drivers/media/video/gspca
parente8b7acc18045afd52c801e196e6a04aefc252795 (diff)
V4L/DVB (12706): gspca - sn9c20x: disable exposure/gain controls for MT9M111 sensors.
Using the MT9M111's IFP to handle exposure/gain gives better results. Signed-off-by: Brian Johnson <brijohn@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/gspca')
-rw-r--r--drivers/media/video/gspca/sn9c20x.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/media/video/gspca/sn9c20x.c b/drivers/media/video/gspca/sn9c20x.c
index e4a021ae9cca..5e01b2845754 100644
--- a/drivers/media/video/gspca/sn9c20x.c
+++ b/drivers/media/video/gspca/sn9c20x.c
@@ -1036,10 +1036,10 @@ static struct i2c_reg_u16 mt9m001_init[] = {
1036}; 1036};
1037 1037
1038static struct i2c_reg_u16 mt9m111_init[] = { 1038static struct i2c_reg_u16 mt9m111_init[] = {
1039 {0xf0, 0x0000}, {0x0d, 0x0008}, {0x0d, 0x0009}, 1039 {0xf0, 0x0000}, {0x0d, 0x0021}, {0x0d, 0x0008},
1040 {0x0d, 0x0008}, {0xf0, 0x0001}, {0x3a, 0x4300}, 1040 {0xf0, 0x0001}, {0x3a, 0x4300}, {0x9b, 0x4300},
1041 {0x9b, 0x4300}, {0xa1, 0x0280}, {0xa4, 0x0200}, 1041 {0xa1, 0x0280}, {0xa4, 0x0200}, {0x06, 0x708e},
1042 {0x06, 0x308e}, {0xf0, 0x0000}, 1042 {0xf0, 0x0002}, {0x2e, 0x0a1e}, {0xf0, 0x0000},
1043}; 1043};
1044 1044
1045static struct i2c_reg_u8 hv7131r_init[] = { 1045static struct i2c_reg_u8 hv7131r_init[] = {
@@ -1379,6 +1379,7 @@ static int mt9m111_init_sensor(struct gspca_dev *gspca_dev)
1379 return -ENODEV; 1379 return -ENODEV;
1380 } 1380 }
1381 } 1381 }
1382 gspca_dev->ctrl_dis = (1 << EXPOSURE_IDX) | (1 << AUTOGAIN_IDX) | (1 << GAIN_IDX);
1382 sd->hstart = 0; 1383 sd->hstart = 0;
1383 sd->vstart = 2; 1384 sd->vstart = 2;
1384 return 0; 1385 return 0;
@@ -1641,7 +1642,6 @@ static int set_exposure(struct gspca_dev *gspca_dev)
1641 exp[4] = sd->exposure >> 8; 1642 exp[4] = sd->exposure >> 8;
1642 break; 1643 break;
1643 case SENSOR_MT9M001: 1644 case SENSOR_MT9M001:
1644 case SENSOR_MT9M111:
1645 case SENSOR_MT9V112: 1645 case SENSOR_MT9V112:
1646 case SENSOR_MT9V111: 1646 case SENSOR_MT9V111:
1647 case SENSOR_MT9V011: 1647 case SENSOR_MT9V011:
@@ -1685,7 +1685,6 @@ static int set_gain(struct gspca_dev *gspca_dev)
1685 gain[4] = micron1_gain[sd->gain] & 0xff; 1685 gain[4] = micron1_gain[sd->gain] & 0xff;
1686 break; 1686 break;
1687 case SENSOR_MT9V112: 1687 case SENSOR_MT9V112:
1688 case SENSOR_MT9M111:
1689 gain[0] |= (3 << 4); 1688 gain[0] |= (3 << 4);
1690 gain[2] = 0x2f; 1689 gain[2] = 0x2f;
1691 gain[3] = micron1_gain[sd->gain] >> 8; 1690 gain[3] = micron1_gain[sd->gain] >> 8;