Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 174133
b: refs/heads/master
c: 69f1fe2
h: refs/heads/master
i:
  174131: 2c2883f
v: v3
  • Loading branch information
Jean-Francois Moine authored and Mauro Carvalho Chehab committed Dec 5, 2009
1 parent 270861d commit 01547a2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 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: b014f94b28713e169a438131a5ce2752068068ad
refs/heads/master: 69f1fe28f08000a123b3d71fac88564109da09fd
15 changes: 7 additions & 8 deletions trunk/drivers/media/video/gspca/ov534.c
Original file line number Diff line number Diff line change
Expand Up @@ -1023,8 +1023,8 @@ static void sccb_w_array(struct gspca_dev *gspca_dev,
}
}

/* set framerate */
static void ov534_set_frame_rate(struct gspca_dev *gspca_dev)
/* ov772x specific controls */
static void set_frame_rate(struct gspca_dev *gspca_dev)
{
struct sd *sd = (struct sd *) gspca_dev;
int i;
Expand Down Expand Up @@ -1072,7 +1072,6 @@ static void ov534_set_frame_rate(struct gspca_dev *gspca_dev)
PDEBUG(D_PROBE, "frame_rate: %d", r->fps);
}

/* ov772x controls */
static void setbrightness(struct gspca_dev *gspca_dev)
{
struct sd *sd = (struct sd *) gspca_dev;
Expand Down Expand Up @@ -1292,7 +1291,7 @@ static int sd_init(struct gspca_dev *gspca_dev)
ARRAY_SIZE(sensor_init_ov772x));
ov534_reg_write(gspca_dev, 0xe0, 0x09);
ov534_set_led(gspca_dev, 0);
ov534_set_frame_rate(gspca_dev);
set_frame_rate(gspca_dev);
break;
default:
/* case SENSOR_OV965X: */
Expand Down Expand Up @@ -1329,7 +1328,7 @@ static int sd_start_ov772x(struct gspca_dev *gspca_dev)
sccb_w_array(gspca_dev, sensor_start_ov772x_vga,
ARRAY_SIZE(sensor_start_ov772x_vga));
}
ov534_set_frame_rate(gspca_dev);
set_frame_rate(gspca_dev);

setautogain(gspca_dev);
setawb(gspca_dev);
Expand Down Expand Up @@ -1518,7 +1517,7 @@ static int sd_setbrightness(struct gspca_dev *gspca_dev, __s32 val)

sd->brightness = val;
if (gspca_dev->streaming)
setcontrast(gspca_dev);
setbrightness(gspca_dev);
return 0;
}

Expand Down Expand Up @@ -1723,8 +1722,8 @@ static int sd_set_streamparm(struct gspca_dev *gspca_dev,

/* Set requested framerate */
sd->frame_rate = tpf->denominator / tpf->numerator;
if (gspca_dev->streaming)
ov534_set_frame_rate(gspca_dev);
if (gspca_dev->streaming && sd->sensor == SENSOR_OV772X)
set_frame_rate(gspca_dev);

/* Return the actual framerate */
tpf->numerator = 1;
Expand Down

0 comments on commit 01547a2

Please sign in to comment.