diff options
author | Jean-Francois Moine <moinejf@free.fr> | 2009-01-20 14:03:31 +0100 |
---|---|---|
committer | Jean-Francois Moine <moinejf@free.fr> | 2009-01-20 14:03:31 +0100 |
commit | 7eeca606e6f069419f33e54b3eda52bfe545bc43 (patch) | |
tree | e2202d2a5f34b5b12ea99c552eb76d943a2de279 /linux/drivers/media/video/gspca/etoms.c | |
parent | 8b8d5d53029339f50706bc1a3b099cedae2abf6a (diff) | |
parent | 5b8037b48a2ec01ef6b8cb460a96db73d5d276ba (diff) | |
download | mediapointer-dvb-s2-7eeca606e6f069419f33e54b3eda52bfe545bc43.tar.gz mediapointer-dvb-s2-7eeca606e6f069419f33e54b3eda52bfe545bc43.tar.bz2 |
merge:v4l-dvb
Diffstat (limited to 'linux/drivers/media/video/gspca/etoms.c')
-rw-r--r-- | linux/drivers/media/video/gspca/etoms.c | 36 |
1 files changed, 4 insertions, 32 deletions
diff --git a/linux/drivers/media/video/gspca/etoms.c b/linux/drivers/media/video/gspca/etoms.c index 84b56c303..84f3a5eb8 100644 --- a/linux/drivers/media/video/gspca/etoms.c +++ b/linux/drivers/media/video/gspca/etoms.c @@ -472,19 +472,6 @@ static void setbrightness(struct gspca_dev *gspca_dev) reg_w_val(gspca_dev, ET_O_RED + i, brightness); } -static void getbrightness(struct gspca_dev *gspca_dev) -{ - struct sd *sd = (struct sd *) gspca_dev; - int i; - int brightness = 0; - - for (i = 0; i < 4; i++) { - reg_r(gspca_dev, ET_O_RED + i, 1); - brightness += gspca_dev->usb_buf[0]; - } - sd->brightness = brightness >> 3; -} - static void setcontrast(struct gspca_dev *gspca_dev) { struct sd *sd = (struct sd *) gspca_dev; @@ -495,19 +482,6 @@ static void setcontrast(struct gspca_dev *gspca_dev) reg_w(gspca_dev, ET_G_RED, RGBG, 6); } -static void getcontrast(struct gspca_dev *gspca_dev) -{ - struct sd *sd = (struct sd *) gspca_dev; - int i; - int contrast = 0; - - for (i = 0; i < 4; i++) { - reg_r(gspca_dev, ET_G_RED + i, 1); - contrast += gspca_dev->usb_buf[0]; - } - sd->contrast = contrast >> 2; -} - static void setcolors(struct gspca_dev *gspca_dev) { struct sd *sd = (struct sd *) gspca_dev; @@ -658,7 +632,6 @@ static int sd_config(struct gspca_dev *gspca_dev, struct cam *cam; cam = &gspca_dev->cam; - cam->epaddr = 1; sd->sensor = id->driver_info; if (sd->sensor == SENSOR_PAS106) { cam->cam_mode = sif_mode; @@ -827,7 +800,6 @@ static int sd_getbrightness(struct gspca_dev *gspca_dev, __s32 *val) { struct sd *sd = (struct sd *) gspca_dev; - getbrightness(gspca_dev); *val = sd->brightness; return 0; } @@ -846,7 +818,6 @@ static int sd_getcontrast(struct gspca_dev *gspca_dev, __s32 *val) { struct sd *sd = (struct sd *) gspca_dev; - getcontrast(gspca_dev); *val = sd->contrast; return 0; } @@ -865,7 +836,6 @@ static int sd_getcolors(struct gspca_dev *gspca_dev, __s32 *val) { struct sd *sd = (struct sd *) gspca_dev; - getcolors(gspca_dev); *val = sd->colors; return 0; } @@ -934,8 +904,10 @@ static struct usb_driver sd_driver = { /* -- module insert / remove -- */ static int __init sd_mod_init(void) { - if (usb_register(&sd_driver) < 0) - return -1; + int ret; + ret = usb_register(&sd_driver); + if (ret < 0) + return ret; PDEBUG(D_PROBE, "registered"); return 0; } |