aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAntti Palosaari <crope@iki.fi>2009-09-15 13:42:13 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-09-18 23:15:32 -0400
commit285eb1a40242adb3feaf9c73d352cbfeee1bea1c (patch)
treeb1ccc7c1c95f084016e3b9166c2defb90f9af7ff /drivers
parente558170a91677d3065be3922bb4467d8969d875c (diff)
V4L/DVB (12951): em28xx: add Reddo DVB-C USB TV Box
Support for Reddo DVB-C USB TV Box device. Remote is not working yet. Thanks to Benjamin Larsson <banan@ludd.ltu.se> Cc: Benjamin Larsson <banan@ludd.ltu.se> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/video/em28xx/Kconfig1
-rw-r--r--drivers/media/video/em28xx/em28xx-cards.c24
-rw-r--r--drivers/media/video/em28xx/em28xx-dvb.c19
-rw-r--r--drivers/media/video/em28xx/em28xx.h1
4 files changed, 45 insertions, 0 deletions
diff --git a/drivers/media/video/em28xx/Kconfig b/drivers/media/video/em28xx/Kconfig
index 6524b493e03..c7be0e09782 100644
--- a/drivers/media/video/em28xx/Kconfig
+++ b/drivers/media/video/em28xx/Kconfig
@@ -36,6 +36,7 @@ config VIDEO_EM28XX_DVB
36 depends on VIDEO_EM28XX && DVB_CORE 36 depends on VIDEO_EM28XX && DVB_CORE
37 select DVB_LGDT330X if !DVB_FE_CUSTOMISE 37 select DVB_LGDT330X if !DVB_FE_CUSTOMISE
38 select DVB_ZL10353 if !DVB_FE_CUSTOMISE 38 select DVB_ZL10353 if !DVB_FE_CUSTOMISE
39 select DVB_TDA10023 if !DVB_FE_CUSTOMISE
39 select VIDEOBUF_DVB 40 select VIDEOBUF_DVB
40 ---help--- 41 ---help---
41 This adds support for DVB cards based on the 42 This adds support for DVB cards based on the
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c
index 2479c6f8641..8a5ce818170 100644
--- a/drivers/media/video/em28xx/em28xx-cards.c
+++ b/drivers/media/video/em28xx/em28xx-cards.c
@@ -170,6 +170,19 @@ static struct em28xx_reg_seq pinnacle_hybrid_pro_digital[] = {
170 { -1, -1, -1, -1}, 170 { -1, -1, -1, -1},
171}; 171};
172 172
173/* eb1a:2868 Reddo DVB-C USB TV Box
174 GPIO4 - CU1216L NIM
175 Other GPIOs seems to be don't care. */
176static struct em28xx_reg_seq reddo_dvb_c_usb_box[] = {
177 {EM28XX_R08_GPIO, 0xfe, 0xff, 10},
178 {EM28XX_R08_GPIO, 0xde, 0xff, 10},
179 {EM28XX_R08_GPIO, 0xfe, 0xff, 10},
180 {EM28XX_R08_GPIO, 0xff, 0xff, 10},
181 {EM28XX_R08_GPIO, 0x7f, 0xff, 10},
182 {EM28XX_R08_GPIO, 0x6f, 0xff, 10},
183 {EM28XX_R08_GPIO, 0xff, 0xff, 10},
184 {-1, -1, -1, -1},
185};
173 186
174/* Callback for the most boards */ 187/* Callback for the most boards */
175static struct em28xx_reg_seq default_tuner_gpio[] = { 188static struct em28xx_reg_seq default_tuner_gpio[] = {
@@ -1566,6 +1579,14 @@ struct em28xx_board em28xx_boards[] = {
1566 .gpio = evga_indtube_analog, 1579 .gpio = evga_indtube_analog,
1567 } }, 1580 } },
1568 }, 1581 },
1582 /* eb1a:2868 Empia EM2870 + Philips CU1216L NIM (Philips TDA10023 +
1583 Infineon TUA6034) */
1584 [EM2870_BOARD_REDDO_DVB_C_USB_BOX] = {
1585 .name = "Reddo DVB-C USB TV Box",
1586 .tuner_type = TUNER_ABSENT,
1587 .has_dvb = 1,
1588 .dvb_gpio = reddo_dvb_c_usb_box,
1589 },
1569}; 1590};
1570const unsigned int em28xx_bcount = ARRAY_SIZE(em28xx_boards); 1591const unsigned int em28xx_bcount = ARRAY_SIZE(em28xx_boards);
1571 1592
@@ -1593,6 +1614,8 @@ struct usb_device_id em28xx_id_table[] = {
1593 .driver_info = EM2820_BOARD_UNKNOWN }, 1614 .driver_info = EM2820_BOARD_UNKNOWN },
1594 { USB_DEVICE(0xeb1a, 0x2883), 1615 { USB_DEVICE(0xeb1a, 0x2883),
1595 .driver_info = EM2820_BOARD_UNKNOWN }, 1616 .driver_info = EM2820_BOARD_UNKNOWN },
1617 { USB_DEVICE(0xeb1a, 0x2868),
1618 .driver_info = EM2820_BOARD_UNKNOWN },
1596 { USB_DEVICE(0xeb1a, 0xe300), 1619 { USB_DEVICE(0xeb1a, 0xe300),
1597 .driver_info = EM2861_BOARD_KWORLD_PVRTV_300U }, 1620 .driver_info = EM2861_BOARD_KWORLD_PVRTV_300U },
1598 { USB_DEVICE(0xeb1a, 0xe303), 1621 { USB_DEVICE(0xeb1a, 0xe303),
@@ -1696,6 +1719,7 @@ static struct em28xx_hash_table em28xx_eeprom_hash[] = {
1696 {0x166a0441, EM2880_BOARD_EMPIRE_DUAL_TV, TUNER_XC2028}, 1719 {0x166a0441, EM2880_BOARD_EMPIRE_DUAL_TV, TUNER_XC2028},
1697 {0xcee44a99, EM2882_BOARD_EVGA_INDTUBE, TUNER_XC2028}, 1720 {0xcee44a99, EM2882_BOARD_EVGA_INDTUBE, TUNER_XC2028},
1698 {0xb8846b20, EM2881_BOARD_PINNACLE_HYBRID_PRO, TUNER_XC2028}, 1721 {0xb8846b20, EM2881_BOARD_PINNACLE_HYBRID_PRO, TUNER_XC2028},
1722 {0x63f653bd, EM2870_BOARD_REDDO_DVB_C_USB_BOX, TUNER_ABSENT},
1699}; 1723};
1700 1724
1701/* I2C devicelist hash table for devices with generic USB IDs */ 1725/* I2C devicelist hash table for devices with generic USB IDs */
diff --git a/drivers/media/video/em28xx/em28xx-dvb.c b/drivers/media/video/em28xx/em28xx-dvb.c
index d603575431b..db749461e5c 100644
--- a/drivers/media/video/em28xx/em28xx-dvb.c
+++ b/drivers/media/video/em28xx/em28xx-dvb.c
@@ -33,6 +33,7 @@
33#include "s5h1409.h" 33#include "s5h1409.h"
34#include "mt352.h" 34#include "mt352.h"
35#include "mt352_priv.h" /* FIXME */ 35#include "mt352_priv.h" /* FIXME */
36#include "tda1002x.h"
36 37
37MODULE_DESCRIPTION("driver for em28xx based DVB cards"); 38MODULE_DESCRIPTION("driver for em28xx based DVB cards");
38MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@infradead.org>"); 39MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@infradead.org>");
@@ -295,6 +296,11 @@ static struct mt352_config terratec_xs_mt352_cfg = {
295 .demod_init = mt352_terratec_xs_init, 296 .demod_init = mt352_terratec_xs_init,
296}; 297};
297 298
299static struct tda10023_config em28xx_tda10023_config = {
300 .demod_address = 0x0c,
301 .invert = 1,
302};
303
298/* ------------------------------------------------------------------ */ 304/* ------------------------------------------------------------------ */
299 305
300static int attach_xc3028(u8 addr, struct em28xx *dev) 306static int attach_xc3028(u8 addr, struct em28xx *dev)
@@ -549,6 +555,19 @@ static int dvb_init(struct em28xx *dev)
549 } 555 }
550 break; 556 break;
551#endif 557#endif
558 case EM2870_BOARD_REDDO_DVB_C_USB_BOX:
559 /* Philips CU1216L NIM (Philips TDA10023 + Infineon TUA6034) */
560 dvb->frontend = dvb_attach(tda10023_attach,
561 &em28xx_tda10023_config,
562 &dev->i2c_adap, 0x48);
563 if (dvb->frontend) {
564 if (!dvb_attach(simple_tuner_attach, dvb->frontend,
565 &dev->i2c_adap, 0x60, TUNER_PHILIPS_CU1216L)) {
566 result = -EINVAL;
567 goto out_free;
568 }
569 }
570 break;
552 default: 571 default:
553 printk(KERN_ERR "%s/2: The frontend of your DVB/ATSC card" 572 printk(KERN_ERR "%s/2: The frontend of your DVB/ATSC card"
554 " isn't supported yet\n", 573 " isn't supported yet\n",
diff --git a/drivers/media/video/em28xx/em28xx.h b/drivers/media/video/em28xx/em28xx.h
index b4a6e07236d..0a73e8bf0d6 100644
--- a/drivers/media/video/em28xx/em28xx.h
+++ b/drivers/media/video/em28xx/em28xx.h
@@ -109,6 +109,7 @@
109#define EM2882_BOARD_EVGA_INDTUBE 70 109#define EM2882_BOARD_EVGA_INDTUBE 70
110#define EM2820_BOARD_SILVERCREST_WEBCAM 71 110#define EM2820_BOARD_SILVERCREST_WEBCAM 71
111#define EM2861_BOARD_GADMEI_UTV330PLUS 72 111#define EM2861_BOARD_GADMEI_UTV330PLUS 72
112#define EM2870_BOARD_REDDO_DVB_C_USB_BOX 73
112 113
113/* Limits minimum and default number of buffers */ 114/* Limits minimum and default number of buffers */
114#define EM28XX_MIN_BUF 4 115#define EM28XX_MIN_BUF 4