summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/gspca/spca505.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2009-06-21 15:09:45 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-06-21 15:09:45 -0300
commit0b8face2f09a06c0608472c22fe5a704b6dc4c0e (patch)
tree39d774e364a86e831312c1568cd8438afcd773c8 /linux/drivers/media/video/gspca/spca505.c
parent04ef26ec109fff2b6d310da4dabdafc4135ad058 (diff)
parent85a3fd2b44d6162a4288a264537c287adf79b4f9 (diff)
downloadmediapointer-dvb-s2-0b8face2f09a06c0608472c22fe5a704b6dc4c0e.tar.gz
mediapointer-dvb-s2-0b8face2f09a06c0608472c22fe5a704b6dc4c0e.tar.bz2
merge: http://kernellabs.com/hg/~mkrufky/bug-fix
From: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video/gspca/spca505.c')
-rw-r--r--linux/drivers/media/video/gspca/spca505.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/linux/drivers/media/video/gspca/spca505.c b/linux/drivers/media/video/gspca/spca505.c
index 2acec58b1..ea8c9fe2e 100644
--- a/linux/drivers/media/video/gspca/spca505.c
+++ b/linux/drivers/media/video/gspca/spca505.c
@@ -637,19 +637,19 @@ static int sd_config(struct gspca_dev *gspca_dev,
cam->nmodes = ARRAY_SIZE(vga_mode) - 1;
sd->brightness = BRIGHTNESS_DEF;
- if (sd->subtype == Nxultra) {
- if (write_vector(gspca_dev, spca505b_init_data))
- return -EIO;
- } else {
- if (write_vector(gspca_dev, spca505_init_data))
- return -EIO;
- }
return 0;
}
/* this function is called at probe and resume time */
static int sd_init(struct gspca_dev *gspca_dev)
{
+ struct sd *sd = (struct sd *) gspca_dev;
+
+ if (write_vector(gspca_dev,
+ sd->subtype == Nxultra
+ ? spca505b_init_data
+ : spca505_init_data))
+ return -EIO;
return 0;
}