]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
media: cx88: Add support for NotOnlyTV LV3H card
authorDaniel Gonzalez Cabanelas <dgcbueu@gmail.com>
Wed, 11 Sep 2019 17:57:06 +0000 (14:57 -0300)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Thu, 10 Oct 2019 10:17:19 +0000 (07:17 -0300)
Add support for the PCI hybrid card NotOnlyTV LV3H. This card consists of:
- A/V Controller: Conexant CX-23883
- Tuner: Xceive XC3028L
- DVB-T Decoder: Zarlink ZL10353

This patch adds support for DVB-T,  Analog TV, FM radio, composite and
S-video inputs. The IR input isn't supported.

Since the PCI subsystem ID (14f1:8852) is the same as the Geniatech
X8000-MT, but they are different boards, the card is only supported via
insmod option: options cx88xx card=91

For the record this is the eeprom dump, useful if someone wanted to
implement the card auto detection:

07 ff ff ff f1 14 52 88 04 04 32 55 f8 00 a2 02
a1 00 40 63 06 11 44 30 03 df 40 80 00 20 00 73
3c 10 00 00 00 00 ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ff ff ff ff ff ff ff ff ff ff ff ff ff ff a0 00

Signed-off-by: Daniel Gonzalez Cabanelas <dgcbueu@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/pci/cx88/cx88-cards.c
drivers/media/pci/cx88/cx88-dvb.c
drivers/media/pci/cx88/cx88.h

index 3cd87626cd7968446be1a96b948d8fa7b014d102..9fa388626bae0df1b67ee22c01a0fe6d07b5a876 100644 (file)
@@ -1781,6 +1781,41 @@ static const struct cx88_board cx88_boards[] = {
                },
                .mpeg           = CX88_MPEG_DVB,
        },
+       [CX88_BOARD_NOTONLYTV_LV3H] = {
+               .name           = "NotOnlyTV LV3H",
+               .tuner_type     = TUNER_XC2028,
+               .radio_type     = UNSET,
+               .tuner_addr     = 0x61,
+               .radio_addr     = ADDR_UNSET,
+               /* if gpio1:bit9 is enabled, DVB-T won't work */
+
+               .input          = { {
+                       .type   = CX88_VMUX_TELEVISION,
+                       .vmux   = 0,
+                       .gpio0  = 0x0000,
+                       .gpio1  = 0xa141,
+                       .gpio2  = 0x0000,
+               }, {
+                       .type   = CX88_VMUX_COMPOSITE1,
+                       .vmux   = 1,
+                       .gpio0  = 0x0000,
+                       .gpio1  = 0xa161,
+                       .gpio2  = 0x0000,
+               }, {
+                       .type   = CX88_VMUX_SVIDEO,
+                       .vmux   = 2,
+                       .gpio0  = 0x0000,
+                       .gpio1  = 0xa161,
+                       .gpio2  = 0x0000,
+               } },
+               .radio = {
+                       .type   = CX88_RADIO,
+                       .gpio0  = 0x0000,
+                       .gpio1  = 0xa141,
+                       .gpio2  = 0x0000,
+               },
+               .mpeg           = CX88_MPEG_DVB,
+       },
        [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO] = {
                .name           = "DViCO FusionHDTV DVB-T PRO",
                .tuner_type     = TUNER_XC2028,
@@ -2654,6 +2689,7 @@ static const struct cx88_subid cx88_subids[] = {
                .subdevice = 0x6f18,
                .card      = CX88_BOARD_WINFAST_TV2000_XP_GLOBAL,
        }, {
+               /* Also NotOnlyTV LV3H (version 1.11 is silkscreened on the board) */
                .subvendor = 0x14f1,
                .subdevice = 0x8852,
                .card      = CX88_BOARD_GENIATECH_X8000_MT,
@@ -3121,6 +3157,7 @@ static int cx88_xc2028_tuner_callback(struct cx88_core *core,
        case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO:
        case CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO:
                return cx88_dvico_xc2028_callback(core, command, arg);
+       case CX88_BOARD_NOTONLYTV_LV3H:
        case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
        case CX88_BOARD_WINFAST_DTV1800H:
                return cx88_xc3028_winfast1800h_callback(core, command, arg);
@@ -3322,6 +3359,7 @@ static void cx88_card_setup_pre_i2c(struct cx88_core *core)
                udelay(1000);
                break;
 
+       case CX88_BOARD_NOTONLYTV_LV3H:
        case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
        case CX88_BOARD_WINFAST_DTV1800H:
                cx88_xc3028_winfast1800h_callback(core, XC2028_TUNER_RESET, 0);
@@ -3378,6 +3416,11 @@ void cx88_setup_xc3028(struct cx88_core *core, struct xc2028_ctrl *ctl)
                 */
                ctl->disable_power_mgmt = 1;
                break;
+       case CX88_BOARD_NOTONLYTV_LV3H:
+               ctl->demod                      = XC3028_FE_ZARLINK456;
+               ctl->fname                      = XC3028L_DEFAULT_FIRMWARE;
+               ctl->read_not_reliable  = 1;
+               break;
        case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
        case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
        case CX88_BOARD_PROLINK_PV_8000GT:
index 0292d0947cc7e13769c103264994b080045b23e6..202ff9e8c2571e96a9078a9275ce1565b3cec6e2 100644 (file)
@@ -1378,6 +1378,7 @@ static int dvb_register(struct cx8802_dev *dev)
                                fe->ops.tuner_ops.set_config(fe, &ctl);
                }
                break;
+       case CX88_BOARD_NOTONLYTV_LV3H:
        case CX88_BOARD_PINNACLE_HYBRID_PCTV:
        case CX88_BOARD_WINFAST_DTV1800H:
                fe0->dvb.frontend = dvb_attach(zl10353_attach,
index 744a22328ebc9bd6f45863e9fc8551767aaaf2f6..ce4acf6de6aa4d347b13563e9674ce4e71cbddbd 100644 (file)
@@ -228,6 +228,7 @@ extern const struct sram_channel cx88_sram_channels[];
 #define CX88_BOARD_WINFAST_DTV1800H_XC4000 88
 #define CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F36 89
 #define CX88_BOARD_WINFAST_TV2000_XP_GLOBAL_6F43 90
+#define CX88_BOARD_NOTONLYTV_LV3H          91
 
 enum cx88_itype {
        CX88_VMUX_COMPOSITE1 = 1,