| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * device driver for Conexant 2388x based TV cards |
|---|
| 3 | 4 | * card-specific stuff. |
|---|
| 4 | 5 | * |
|---|
| 5 | 6 | * (c) 2003 Gerd Knorr <kraxel@bytesex.org> [SuSE Labs] |
|---|
| 6 | | - * |
|---|
| 7 | | - * This program is free software; you can redistribute it and/or modify |
|---|
| 8 | | - * it under the terms of the GNU General Public License as published by |
|---|
| 9 | | - * the Free Software Foundation; either version 2 of the License, or |
|---|
| 10 | | - * (at your option) any later version. |
|---|
| 11 | | - * |
|---|
| 12 | | - * This program is distributed in the hope that it will be useful, |
|---|
| 13 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 14 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 15 | | - * GNU General Public License for more details. |
|---|
| 16 | 7 | */ |
|---|
| 17 | 8 | |
|---|
| 18 | 9 | #include "cx88.h" |
|---|
| .. | .. |
|---|
| 1790 | 1781 | }, |
|---|
| 1791 | 1782 | .mpeg = CX88_MPEG_DVB, |
|---|
| 1792 | 1783 | }, |
|---|
| 1784 | + [CX88_BOARD_NOTONLYTV_LV3H] = { |
|---|
| 1785 | + .name = "NotOnlyTV LV3H", |
|---|
| 1786 | + .tuner_type = TUNER_XC2028, |
|---|
| 1787 | + .radio_type = UNSET, |
|---|
| 1788 | + .tuner_addr = 0x61, |
|---|
| 1789 | + .radio_addr = ADDR_UNSET, |
|---|
| 1790 | + /* if gpio1:bit9 is enabled, DVB-T won't work */ |
|---|
| 1791 | + |
|---|
| 1792 | + .input = { { |
|---|
| 1793 | + .type = CX88_VMUX_TELEVISION, |
|---|
| 1794 | + .vmux = 0, |
|---|
| 1795 | + .gpio0 = 0x0000, |
|---|
| 1796 | + .gpio1 = 0xa141, |
|---|
| 1797 | + .gpio2 = 0x0000, |
|---|
| 1798 | + }, { |
|---|
| 1799 | + .type = CX88_VMUX_COMPOSITE1, |
|---|
| 1800 | + .vmux = 1, |
|---|
| 1801 | + .gpio0 = 0x0000, |
|---|
| 1802 | + .gpio1 = 0xa161, |
|---|
| 1803 | + .gpio2 = 0x0000, |
|---|
| 1804 | + }, { |
|---|
| 1805 | + .type = CX88_VMUX_SVIDEO, |
|---|
| 1806 | + .vmux = 2, |
|---|
| 1807 | + .gpio0 = 0x0000, |
|---|
| 1808 | + .gpio1 = 0xa161, |
|---|
| 1809 | + .gpio2 = 0x0000, |
|---|
| 1810 | + } }, |
|---|
| 1811 | + .radio = { |
|---|
| 1812 | + .type = CX88_RADIO, |
|---|
| 1813 | + .gpio0 = 0x0000, |
|---|
| 1814 | + .gpio1 = 0xa141, |
|---|
| 1815 | + .gpio2 = 0x0000, |
|---|
| 1816 | + }, |
|---|
| 1817 | + .mpeg = CX88_MPEG_DVB, |
|---|
| 1818 | + }, |
|---|
| 1793 | 1819 | [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO] = { |
|---|
| 1794 | 1820 | .name = "DViCO FusionHDTV DVB-T PRO", |
|---|
| 1795 | 1821 | .tuner_type = TUNER_XC2028, |
|---|
| .. | .. |
|---|
| 2663 | 2689 | .subdevice = 0x6f18, |
|---|
| 2664 | 2690 | .card = CX88_BOARD_WINFAST_TV2000_XP_GLOBAL, |
|---|
| 2665 | 2691 | }, { |
|---|
| 2692 | + /* Also NotOnlyTV LV3H (version 1.11 is silkscreened on the board) */ |
|---|
| 2666 | 2693 | .subvendor = 0x14f1, |
|---|
| 2667 | 2694 | .subdevice = 0x8852, |
|---|
| 2668 | 2695 | .card = CX88_BOARD_GENIATECH_X8000_MT, |
|---|
| .. | .. |
|---|
| 3130 | 3157 | case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO: |
|---|
| 3131 | 3158 | case CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO: |
|---|
| 3132 | 3159 | return cx88_dvico_xc2028_callback(core, command, arg); |
|---|
| 3160 | + case CX88_BOARD_NOTONLYTV_LV3H: |
|---|
| 3133 | 3161 | case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL: |
|---|
| 3134 | 3162 | case CX88_BOARD_WINFAST_DTV1800H: |
|---|
| 3135 | 3163 | return cx88_xc3028_winfast1800h_callback(core, command, arg); |
|---|
| .. | .. |
|---|
| 3331 | 3359 | udelay(1000); |
|---|
| 3332 | 3360 | break; |
|---|
| 3333 | 3361 | |
|---|
| 3362 | + case CX88_BOARD_NOTONLYTV_LV3H: |
|---|
| 3334 | 3363 | case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL: |
|---|
| 3335 | 3364 | case CX88_BOARD_WINFAST_DTV1800H: |
|---|
| 3336 | 3365 | cx88_xc3028_winfast1800h_callback(core, XC2028_TUNER_RESET, 0); |
|---|
| .. | .. |
|---|
| 3386 | 3415 | * power management for now |
|---|
| 3387 | 3416 | */ |
|---|
| 3388 | 3417 | ctl->disable_power_mgmt = 1; |
|---|
| 3418 | + break; |
|---|
| 3419 | + case CX88_BOARD_NOTONLYTV_LV3H: |
|---|
| 3420 | + ctl->demod = XC3028_FE_ZARLINK456; |
|---|
| 3421 | + ctl->fname = XC3028L_DEFAULT_FIRMWARE; |
|---|
| 3422 | + ctl->read_not_reliable = 1; |
|---|
| 3389 | 3423 | break; |
|---|
| 3390 | 3424 | case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL: |
|---|
| 3391 | 3425 | case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME: |
|---|
| .. | .. |
|---|
| 3465 | 3499 | cx_clear(MO_GP0_IO, 0x00000040); |
|---|
| 3466 | 3500 | msleep(1000); |
|---|
| 3467 | 3501 | cx_set(MO_GP0_IO, 0x00004040); |
|---|
| 3468 | | - /* FALLTHROUGH */ |
|---|
| 3502 | + fallthrough; |
|---|
| 3469 | 3503 | case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1: |
|---|
| 3470 | 3504 | case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS: |
|---|
| 3471 | 3505 | case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_HYBRID: |
|---|
| .. | .. |
|---|
| 3693 | 3727 | core->height = 240; |
|---|
| 3694 | 3728 | core->field = V4L2_FIELD_INTERLACED; |
|---|
| 3695 | 3729 | |
|---|
| 3696 | | - strcpy(core->v4l2_dev.name, core->name); |
|---|
| 3730 | + strscpy(core->v4l2_dev.name, core->name, sizeof(core->v4l2_dev.name)); |
|---|
| 3697 | 3731 | if (v4l2_device_register(NULL, &core->v4l2_dev)) { |
|---|
| 3698 | 3732 | kfree(core); |
|---|
| 3699 | 3733 | return NULL; |
|---|