summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/gspca
diff options
context:
space:
mode:
authorJean-Francois Moine <moinejf@free.fr>2008-11-17 18:56:41 +0100
committerJean-Francois Moine <moinejf@free.fr>2008-11-17 18:56:41 +0100
commitff8138511038450f4fd212669615835c98822d17 (patch)
treed3e2713b0262af640e43ab6d7ccc3fe58e09cd97 /linux/drivers/media/video/gspca
parentc965174067222d803288076b540514a554cb14e8 (diff)
downloadmediapointer-dvb-s2-ff8138511038450f4fd212669615835c98822d17.tar.gz
mediapointer-dvb-s2-ff8138511038450f4fd212669615835c98822d17.tar.bz2
gspca: Don't return the control values from the webcams in spca501.
From: Hans de Goede <hdegoede@redhat.com> The bridge takes some time to update after a write, so apps doing a quick write/read can get the old value back. Priority: normal Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Diffstat (limited to 'linux/drivers/media/video/gspca')
-rw-r--r--linux/drivers/media/video/gspca/spca501.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/linux/drivers/media/video/gspca/spca501.c b/linux/drivers/media/video/gspca/spca501.c
index 3af5f9d60..29277bdda 100644
--- a/linux/drivers/media/video/gspca/spca501.c
+++ b/linux/drivers/media/video/gspca/spca501.c
@@ -1822,6 +1822,7 @@ static int reg_write(struct usb_device *dev,
return ret;
}
+#if 0
/* returns: negative is error, pos or zero is data */
static int reg_read(struct gspca_dev *gspca_dev,
__u16 req, /* bRequest */
@@ -1845,6 +1846,7 @@ static int reg_read(struct gspca_dev *gspca_dev,
}
return (gspca_dev->usb_buf[1] << 8) + gspca_dev->usb_buf[0];
}
+#endif
static int write_vector(struct gspca_dev *gspca_dev,
const __u16 data[][3])
@@ -1876,11 +1878,13 @@ static void setbrightness(struct gspca_dev *gspca_dev)
static void getbrightness(struct gspca_dev *gspca_dev)
{
+#if 0
struct sd *sd = (struct sd *) gspca_dev;
__u16 brightness;
brightness = reg_read(gspca_dev, SPCA501_REG_CCDSP, 0x11, 2);
- sd->brightness = brightness << 1;
+ sd->brightness = brightness;
+#endif
}
static void setcontrast(struct gspca_dev *gspca_dev)
@@ -1906,7 +1910,6 @@ static void getcontrast(struct gspca_dev *gspca_dev)
0x01,
1) & 0xff);
#endif
-/* spca50x->contrast = 0xaa01; */
}
static void setcolors(struct gspca_dev *gspca_dev)
@@ -1918,11 +1921,13 @@ static void setcolors(struct gspca_dev *gspca_dev)
static void getcolors(struct gspca_dev *gspca_dev)
{
+#if 0
struct sd *sd = (struct sd *) gspca_dev;
sd->colors = reg_read(gspca_dev, SPCA501_REG_CCDSP, 0x0c, 2);
/* sd->hue = (reg_read(gspca_dev, SPCA501_REG_CCDSP, 0x13, */
/* 2) & 0xFF) << 8; */
+#endif
}
/* this function is called at probe time */