Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 181715
b: refs/heads/master
c: f6b22e5
h: refs/heads/master
i:
  181713: 0188c21
  181711: 58295b8
v: v3
  • Loading branch information
Jean-François Moine authored and Mauro Carvalho Chehab committed Feb 26, 2010
1 parent 9697f0d commit 82431ce
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bee527f97963ece5e3f6e6587402197af889865b
refs/heads/master: f6b22e5e8e93d03046d3878664a9ba375ccded96
21 changes: 16 additions & 5 deletions trunk/drivers/media/video/gspca/sonixj.c
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ static const struct ctrl sd_ctrls[] = {
static __u32 ctrl_dis[] = {
(1 << INFRARED_IDX) | (1 << VFLIP_IDX) | (1 << FREQ_IDX) |
(1 << AUTOGAIN_IDX), /* SENSOR_ADCM1700 0 */
(1 << INFRARED_IDX) | (1 << VFLIP_IDX) | (1 << FREQ_IDX),
(1 << INFRARED_IDX) | (1 << FREQ_IDX),
/* SENSOR_HV7131R 1 */
(1 << INFRARED_IDX) | (1 << VFLIP_IDX) | (1 << FREQ_IDX),
/* SENSOR_MI0360 2 */
Expand Down Expand Up @@ -1780,23 +1780,34 @@ static void setautogain(struct gspca_dev *gspca_dev)
sd->ag_cnt = -1;
}

/* ov7630/ov7648 only */
/* hv7131r/ov7630/ov7648 only */
static void setvflip(struct sd *sd)
{
u8 comn;

if (sd->gspca_dev.ctrl_dis & (1 << VFLIP_IDX))
return;
if (sd->sensor == SENSOR_OV7630) {
switch (sd->sensor) {
case SENSOR_HV7131R:
comn = 0x18; /* clkdiv = 1, ablcen = 1 */
if (sd->vflip)
comn |= 0x01;
i2c_w1(&sd->gspca_dev, 0x01, comn); /* sctra */
break;
case SENSOR_OV7630:
comn = 0x02;
if (!sd->vflip)
comn |= 0x80;
} else {
i2c_w1(&sd->gspca_dev, 0x75, comn);
break;
default:
/* case SENSOR_OV7648: */
comn = 0x06;
if (sd->vflip)
comn |= 0x80;
i2c_w1(&sd->gspca_dev, 0x75, comn);
break;
}
i2c_w1(&sd->gspca_dev, 0x75, comn);
}

static void setsharpness(struct sd *sd)
Expand Down

0 comments on commit 82431ce

Please sign in to comment.