summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2008-10-24 18:08:28 +0000
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-10-24 18:08:28 +0000
commit122f8ca9fc2a1fb872708d4135f09d68585e7f0c (patch)
tree33306435c385e0f4e04e769a2e842d517040a033 /linux
parentb12831a462e695841ace55e08ac956e6724ab496 (diff)
downloadmediapointer-dvb-s2-122f8ca9fc2a1fb872708d4135f09d68585e7f0c.tar.gz
mediapointer-dvb-s2-122f8ca9fc2a1fb872708d4135f09d68585e7f0c.tar.bz2
Minor fixes to the saa7110 driver
From: Jean Delvare <khali@linux-fr.org> * Apparently the author of the saa7110 driver was confused by the number of outputs returned by DECODER_GET_CAPABILITIES. Of course a decoder chip has no analog ouputs, but it must have at least one digital output. * Fix an off-by-one error when checking the input value of DECODER_SET_INPUT. Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux')
-rw-r--r--linux/drivers/media/video/saa7110.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/linux/drivers/media/video/saa7110.c b/linux/drivers/media/video/saa7110.c
index 15eb8bd7a..b7afe3124 100644
--- a/linux/drivers/media/video/saa7110.c
+++ b/linux/drivers/media/video/saa7110.c
@@ -48,7 +48,7 @@ module_param(debug, int, 0);
MODULE_PARM_DESC(debug, "Debug level (0-1)");
#define SAA7110_MAX_INPUT 9 /* 6 CVBS, 3 SVHS */
-#define SAA7110_MAX_OUTPUT 0 /* its a decoder only */
+#define SAA7110_MAX_OUTPUT 1 /* 1 YUV */
#define SAA7110_NR_REG 0x35
@@ -328,7 +328,7 @@ saa7110_command (struct i2c_client *client,
case DECODER_SET_INPUT:
v = *(int *) arg;
- if (v < 0 || v > SAA7110_MAX_INPUT) {
+ if (v < 0 || v >= SAA7110_MAX_INPUT) {
v4l_dbg(1, debug, client, "input=%d not available\n", v);
return -EINVAL;
}