summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/tvp5150.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2007-11-04 14:18:02 -0200
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-11-04 14:18:02 -0200
commit1dbbdee4213114f49f8fe0d92a6daeba5c6f639f (patch)
tree9dd17b2bd0bc0913493cc7764d7a4d1d4a411bd9 /linux/drivers/media/video/tvp5150.c
parent0d047cc5c24e86c3087e7c2300d048f48a11988a (diff)
parent971898bb2fef994eccedc53e385ec8fec1b01244 (diff)
downloadmediapointer-dvb-s2-1dbbdee4213114f49f8fe0d92a6daeba5c6f639f.tar.gz
mediapointer-dvb-s2-1dbbdee4213114f49f8fe0d92a6daeba5c6f639f.tar.bz2
merge: http://linuxtv.org/hg/~mcisely/pvrusb2
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux/drivers/media/video/tvp5150.c')
-rw-r--r--linux/drivers/media/video/tvp5150.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/linux/drivers/media/video/tvp5150.c b/linux/drivers/media/video/tvp5150.c
index 6be434987..1619c5ff3 100644
--- a/linux/drivers/media/video/tvp5150.c
+++ b/linux/drivers/media/video/tvp5150.c
@@ -320,6 +320,7 @@ static inline void tvp5150_selmux(struct i2c_client *c)
int opmode=0;
struct tvp5150 *decoder = i2c_get_clientdata(c);
int input = 0;
+ unsigned char val;
if ((decoder->route.output & TVP5150_BLACK_SCREEN) || !decoder->enable)
input = 8;
@@ -345,6 +346,16 @@ static inline void tvp5150_selmux(struct i2c_client *c)
tvp5150_write(c, TVP5150_OP_MODE_CTL, opmode);
tvp5150_write(c, TVP5150_VD_IN_SRC_SEL_1, input);
+
+ /* Svideo should enable YCrCb output and disable GPCL output
+ * For Composite and TV, it should be the reverse
+ */
+ val = tvp5150_read(c, TVP5150_MISC_CTL);
+ if (decoder->route.input == TVP5150_SVIDEO)
+ val = (val & ~0x40) | 0x10;
+ else
+ val = (val & ~0x10) | 0x40;
+ tvp5150_write(c, TVP5150_MISC_CTL, val);
};
struct i2c_reg_value {