aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/gspca/zc3xx.c
diff options
context:
space:
mode:
authorJean-Francois Moine <moinejf@free.fr>2009-12-20 03:07:10 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-02-26 13:10:27 -0500
commitd754a6ca9af4ef3eedf9768446689731af09664a (patch)
tree2e3ee76276714721ad635c6ff495154265346dc3 /drivers/media/video/gspca/zc3xx.c
parent658604ec9caa9c8a998e296f689bd85ca1f95d6a (diff)
V4L/DVB (13870): gspca - zc3xx: Bad detection of sensor HV7131R(c).
The webcam 0ac8:303b may have the sensors HV7131B or HV7131R(c). This changeset checks the HV7131 type. 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/zc3xx.c')
-rw-r--r--drivers/media/video/gspca/zc3xx.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/drivers/media/video/gspca/zc3xx.c b/drivers/media/video/gspca/zc3xx.c
index 07dc5b6b4168..e0dd0ea0588e 100644
--- a/drivers/media/video/gspca/zc3xx.c
+++ b/drivers/media/video/gspca/zc3xx.c
@@ -6672,8 +6672,21 @@ static int sd_config(struct gspca_dev *gspca_dev,
6672 } 6672 }
6673 break; 6673 break;
6674 case 0: 6674 case 0:
6675 PDEBUG(D_PROBE, "Find Sensor HV7131B"); 6675 /* check the sensor type */
6676 sd->sensor = SENSOR_HV7131B; 6676 sensor = i2c_read(gspca_dev, 0x00);
6677 PDEBUG(D_PROBE, "Sensor hv7131 type %d", sensor);
6678 switch (sensor) {
6679 case 0: /* hv7131b */
6680 case 1: /* hv7131e */
6681 PDEBUG(D_PROBE, "Find Sensor HV7131B");
6682 sd->sensor = SENSOR_HV7131B;
6683 break;
6684 default:
6685/* case 2: * hv7131r */
6686 PDEBUG(D_PROBE, "Find Sensor HV7131R(c)");
6687 sd->sensor = SENSOR_HV7131C;
6688 break;
6689 }
6677 break; 6690 break;
6678 case 0x02: 6691 case 0x02:
6679 PDEBUG(D_PROBE, "Sensor TAS5130C"); 6692 PDEBUG(D_PROBE, "Sensor TAS5130C");