diff options
author | Antti Palosaari <crope@iki.fi> | 2011-08-01 00:15:30 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-09-21 09:01:47 -0400 |
commit | 36588715fc0ed3ff0ffb025dc841652cb3b2b667 (patch) | |
tree | e687ba6b920bfc300733f817aa923c6e17a2e45a /drivers/media/video/em28xx | |
parent | de8e42035014214708d9e32e12fe6d42a5ae59d1 (diff) |
[media] em28xx: add support for PCTV DVB-S2 Stick 460e [2013:024f]
It is based of...
* Empia EM28174
* NXP TDA10071 & Conexant CX24118A combo
* Allegro A8293
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/em28xx')
-rw-r--r-- | drivers/media/video/em28xx/Kconfig | 2 | ||||
-rw-r--r-- | drivers/media/video/em28xx/em28xx-cards.c | 32 | ||||
-rw-r--r-- | drivers/media/video/em28xx/em28xx-dvb.c | 25 | ||||
-rw-r--r-- | drivers/media/video/em28xx/em28xx.h | 1 |
4 files changed, 60 insertions, 0 deletions
diff --git a/drivers/media/video/em28xx/Kconfig b/drivers/media/video/em28xx/Kconfig index 281ee427c2ab..f6f622e123bd 100644 --- a/drivers/media/video/em28xx/Kconfig +++ b/drivers/media/video/em28xx/Kconfig | |||
@@ -41,6 +41,8 @@ config VIDEO_EM28XX_DVB | |||
41 | select DVB_CXD2820R if !DVB_FE_CUSTOMISE | 41 | select DVB_CXD2820R if !DVB_FE_CUSTOMISE |
42 | select DVB_DRXK if !DVB_FE_CUSTOMISE | 42 | select DVB_DRXK if !DVB_FE_CUSTOMISE |
43 | select DVB_TDA18271C2DD if !DVB_FE_CUSTOMISE | 43 | select DVB_TDA18271C2DD if !DVB_FE_CUSTOMISE |
44 | select DVB_TDA10071 if !DVB_FE_CUSTOMISE | ||
45 | select DVB_A8293 if !DVB_FE_CUSTOMISE | ||
44 | select VIDEOBUF_DVB | 46 | select VIDEOBUF_DVB |
45 | ---help--- | 47 | ---help--- |
46 | This adds support for DVB cards based on the | 48 | 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 013e946bdc45..8845ff8cee50 100644 --- a/drivers/media/video/em28xx/em28xx-cards.c +++ b/drivers/media/video/em28xx/em28xx-cards.c | |||
@@ -317,6 +317,25 @@ static struct em28xx_reg_seq terratec_h5_digital[] = { | |||
317 | }; | 317 | }; |
318 | #endif | 318 | #endif |
319 | 319 | ||
320 | /* 2013:024f PCTV DVB-S2 Stick 460e | ||
321 | * GPIO_0 - POWER_ON | ||
322 | * GPIO_1 - BOOST | ||
323 | * GPIO_2 - VUV_LNB (red LED) | ||
324 | * GPIO_3 - EXT_12V | ||
325 | * GPIO_4 - INT_DEM (DEMOD GPIO_0) | ||
326 | * GPIO_5 - INT_LNB | ||
327 | * GPIO_6 - RESET_DEM | ||
328 | * GPIO_7 - LED (green LED) | ||
329 | */ | ||
330 | static struct em28xx_reg_seq pctv_460e[] = { | ||
331 | {EM2874_R80_GPIO, 0x01, 0xff, 50}, | ||
332 | {0x0d, 0xff, 0xff, 50}, | ||
333 | {EM2874_R80_GPIO, 0x41, 0xff, 50}, /* GPIO_6=1 */ | ||
334 | {0x0d, 0x42, 0xff, 50}, | ||
335 | {EM2874_R80_GPIO, 0x61, 0xff, 50}, /* GPIO_5=1 */ | ||
336 | { -1, -1, -1, -1}, | ||
337 | }; | ||
338 | |||
320 | /* | 339 | /* |
321 | * Board definitions | 340 | * Board definitions |
322 | */ | 341 | */ |
@@ -1810,6 +1829,17 @@ struct em28xx_board em28xx_boards[] = { | |||
1810 | .has_dvb = 1, | 1829 | .has_dvb = 1, |
1811 | .ir_codes = RC_MAP_PINNACLE_PCTV_HD, | 1830 | .ir_codes = RC_MAP_PINNACLE_PCTV_HD, |
1812 | }, | 1831 | }, |
1832 | /* 2013:024f PCTV DVB-S2 Stick 460e | ||
1833 | * Empia EM28174, NXP TDA10071, Conexant CX24118A and Allegro A8293 */ | ||
1834 | [EM28174_BOARD_PCTV_460E] = { | ||
1835 | .i2c_speed = EM2874_I2C_SECONDARY_BUS_SELECT | | ||
1836 | EM28XX_I2C_CLK_WAIT_ENABLE | EM28XX_I2C_FREQ_400_KHZ, | ||
1837 | .name = "PCTV DVB-S2 Stick (460e)", | ||
1838 | .tuner_type = TUNER_ABSENT, | ||
1839 | .tuner_gpio = pctv_460e, | ||
1840 | .has_dvb = 1, | ||
1841 | .ir_codes = RC_MAP_PINNACLE_PCTV_HD, | ||
1842 | }, | ||
1813 | }; | 1843 | }; |
1814 | const unsigned int em28xx_bcount = ARRAY_SIZE(em28xx_boards); | 1844 | const unsigned int em28xx_bcount = ARRAY_SIZE(em28xx_boards); |
1815 | 1845 | ||
@@ -1941,6 +1971,8 @@ struct usb_device_id em28xx_id_table[] = { | |||
1941 | .driver_info = EM2870_BOARD_KWORLD_A340 }, | 1971 | .driver_info = EM2870_BOARD_KWORLD_A340 }, |
1942 | { USB_DEVICE(0x2013, 0x024f), | 1972 | { USB_DEVICE(0x2013, 0x024f), |
1943 | .driver_info = EM28174_BOARD_PCTV_290E }, | 1973 | .driver_info = EM28174_BOARD_PCTV_290E }, |
1974 | { USB_DEVICE(0x2013, 0x024c), | ||
1975 | .driver_info = EM28174_BOARD_PCTV_460E }, | ||
1944 | { }, | 1976 | { }, |
1945 | }; | 1977 | }; |
1946 | MODULE_DEVICE_TABLE(usb, em28xx_id_table); | 1978 | MODULE_DEVICE_TABLE(usb, em28xx_id_table); |
diff --git a/drivers/media/video/em28xx/em28xx-dvb.c b/drivers/media/video/em28xx/em28xx-dvb.c index 62b558ddc02e..cef7a2d409cb 100644 --- a/drivers/media/video/em28xx/em28xx-dvb.c +++ b/drivers/media/video/em28xx/em28xx-dvb.c | |||
@@ -42,6 +42,8 @@ | |||
42 | #include "cxd2820r.h" | 42 | #include "cxd2820r.h" |
43 | #include "tda18271c2dd.h" | 43 | #include "tda18271c2dd.h" |
44 | #include "drxk.h" | 44 | #include "drxk.h" |
45 | #include "tda10071.h" | ||
46 | #include "a8293.h" | ||
45 | 47 | ||
46 | MODULE_DESCRIPTION("driver for em28xx based DVB cards"); | 48 | MODULE_DESCRIPTION("driver for em28xx based DVB cards"); |
47 | MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@infradead.org>"); | 49 | MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@infradead.org>"); |
@@ -441,6 +443,19 @@ static struct tda18271_config em28xx_cxd2820r_tda18271_config = { | |||
441 | .gate = TDA18271_GATE_DIGITAL, | 443 | .gate = TDA18271_GATE_DIGITAL, |
442 | }; | 444 | }; |
443 | 445 | ||
446 | static const struct tda10071_config em28xx_tda10071_config = { | ||
447 | .i2c_address = 0x55, /* (0xaa >> 1) */ | ||
448 | .i2c_wr_max = 64, | ||
449 | .ts_mode = TDA10071_TS_SERIAL, | ||
450 | .spec_inv = 0, | ||
451 | .xtal = 40444000, /* 40.444 MHz */ | ||
452 | .pll_multiplier = 20, | ||
453 | }; | ||
454 | |||
455 | static const struct a8293_config em28xx_a8293_config = { | ||
456 | .i2c_addr = 0x08, /* (0x10 >> 1) */ | ||
457 | }; | ||
458 | |||
444 | /* ------------------------------------------------------------------ */ | 459 | /* ------------------------------------------------------------------ */ |
445 | 460 | ||
446 | static int em28xx_attach_xc3028(u8 addr, struct em28xx *dev) | 461 | static int em28xx_attach_xc3028(u8 addr, struct em28xx *dev) |
@@ -808,6 +823,16 @@ static int em28xx_dvb_init(struct em28xx *dev) | |||
808 | sizeof(dvb->fe[0]->ops.tuner_ops)); | 823 | sizeof(dvb->fe[0]->ops.tuner_ops)); |
809 | 824 | ||
810 | break; | 825 | break; |
826 | case EM28174_BOARD_PCTV_460E: | ||
827 | /* attach demod */ | ||
828 | dvb->fe[0] = dvb_attach(tda10071_attach, | ||
829 | &em28xx_tda10071_config, &dev->i2c_adap); | ||
830 | |||
831 | /* attach SEC */ | ||
832 | if (dvb->fe[0]) | ||
833 | dvb_attach(a8293_attach, dvb->fe[0], &dev->i2c_adap, | ||
834 | &em28xx_a8293_config); | ||
835 | break; | ||
811 | default: | 836 | default: |
812 | em28xx_errdev("/2: The frontend of your DVB/ATSC card" | 837 | em28xx_errdev("/2: The frontend of your DVB/ATSC card" |
813 | " isn't supported yet\n"); | 838 | " isn't supported yet\n"); |
diff --git a/drivers/media/video/em28xx/em28xx.h b/drivers/media/video/em28xx/em28xx.h index d80658bf3da9..1626e4a83407 100644 --- a/drivers/media/video/em28xx/em28xx.h +++ b/drivers/media/video/em28xx/em28xx.h | |||
@@ -120,6 +120,7 @@ | |||
120 | #define EM2874_BOARD_LEADERSHIP_ISDBT 77 | 120 | #define EM2874_BOARD_LEADERSHIP_ISDBT 77 |
121 | #define EM28174_BOARD_PCTV_290E 78 | 121 | #define EM28174_BOARD_PCTV_290E 78 |
122 | #define EM2884_BOARD_TERRATEC_H5 79 | 122 | #define EM2884_BOARD_TERRATEC_H5 79 |
123 | #define EM28174_BOARD_PCTV_460E 80 | ||
123 | 124 | ||
124 | /* Limits minimum and default number of buffers */ | 125 | /* Limits minimum and default number of buffers */ |
125 | #define EM28XX_MIN_BUF 4 | 126 | #define EM28XX_MIN_BUF 4 |