diff options
author | Lukas Karas <lukas.karas@centrum.cz> | 2009-11-24 10:06:52 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-12-15 21:18:25 -0500 |
commit | d995a18733a683c1c086a4d48315976f8c25d89b (patch) | |
tree | 403341b8344062521067c435266b596a9853f69a /drivers/media/video/saa7134/saa7134-cards.c | |
parent | 7eca61eb6a57a3aae10e77d9306cda0b8c23cdab (diff) |
V4L/DVB (13591): add support for IR on FlyDVB Trio (saa7134)
saa7134: Add support for IR reciever on card LifeView FlyDVB Trio
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
[mchehab@redhat.com: CodingStyle fixes and ported upstream]
Tested-by: Petr Fiala <petr.fiala@gmail.com>
Signed-off-by: Lukas Karas <lukas.karas@centrum.cz>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/saa7134/saa7134-cards.c')
-rw-r--r-- | drivers/media/video/saa7134/saa7134-cards.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/drivers/media/video/saa7134/saa7134-cards.c b/drivers/media/video/saa7134/saa7134-cards.c index 7e40d6d99dd0..03f572708b85 100644 --- a/drivers/media/video/saa7134/saa7134-cards.c +++ b/drivers/media/video/saa7134/saa7134-cards.c | |||
@@ -7211,9 +7211,31 @@ int saa7134_board_init2(struct saa7134_dev *dev) | |||
7211 | } | 7211 | } |
7212 | case SAA7134_BOARD_FLYDVB_TRIO: | 7212 | case SAA7134_BOARD_FLYDVB_TRIO: |
7213 | { | 7213 | { |
7214 | u8 temp = 0; | ||
7215 | int rc; | ||
7214 | u8 data[] = { 0x3c, 0x33, 0x62}; | 7216 | u8 data[] = { 0x3c, 0x33, 0x62}; |
7215 | struct i2c_msg msg = {.addr=0x09, .flags=0, .buf=data, .len = sizeof(data)}; | 7217 | struct i2c_msg msg = {.addr=0x09, .flags=0, .buf=data, .len = sizeof(data)}; |
7216 | i2c_transfer(&dev->i2c_adap, &msg, 1); | 7218 | i2c_transfer(&dev->i2c_adap, &msg, 1); |
7219 | |||
7220 | /* | ||
7221 | * send weak up message to pic16C505 chip | ||
7222 | * @ LifeView FlyDVB Trio | ||
7223 | */ | ||
7224 | msg.buf = &temp; | ||
7225 | msg.addr = 0x0b; | ||
7226 | msg.len = 1; | ||
7227 | if (1 != i2c_transfer(&dev->i2c_adap, &msg, 1)) { | ||
7228 | printk(KERN_WARNING "%s: send wake up byte to pic16C505" | ||
7229 | "(IR chip) failed\n", dev->name); | ||
7230 | } else { | ||
7231 | msg.flags = I2C_M_RD; | ||
7232 | rc = i2c_transfer(&dev->i2c_adap, &msg, 1); | ||
7233 | printk(KERN_INFO "%s: probe IR chip @ i2c 0x%02x: %s\n", | ||
7234 | dev->name, msg.addr, | ||
7235 | (1 == rc) ? "yes" : "no"); | ||
7236 | if (rc == 1) | ||
7237 | dev->has_remote = SAA7134_REMOTE_I2C; | ||
7238 | } | ||
7217 | break; | 7239 | break; |
7218 | } | 7240 | } |
7219 | case SAA7134_BOARD_ADS_DUO_CARDBUS_PTV331: | 7241 | case SAA7134_BOARD_ADS_DUO_CARDBUS_PTV331: |