2 * $Id: cx88-cards.c,v 1.90 2005/07/28 02:47:42 mkrufky Exp $
4 * device driver for Conexant 2388x based TV cards
7 * (c) 2003 Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
24 #include <linux/init.h>
25 #include <linux/module.h>
26 #include <linux/pci.h>
27 #include <linux/delay.h>
31 /* ------------------------------------------------------------------ */
32 /* board config info */
34 struct cx88_board cx88_boards[] = {
35 [CX88_BOARD_UNKNOWN] = {
36 .name = "UNKNOWN/GENERIC",
39 .tuner_addr = ADDR_UNSET,
40 .radio_addr = ADDR_UNSET,
42 .type = CX88_VMUX_COMPOSITE1,
45 .type = CX88_VMUX_COMPOSITE2,
48 .type = CX88_VMUX_COMPOSITE3,
51 .type = CX88_VMUX_COMPOSITE4,
55 [CX88_BOARD_HAUPPAUGE] = {
56 .name = "Hauppauge WinTV 34xxx models",
59 .tuner_addr = ADDR_UNSET,
60 .radio_addr = ADDR_UNSET,
61 .tda9887_conf = TDA9887_PRESENT,
63 .type = CX88_VMUX_TELEVISION,
65 .gpio0 = 0xff00, // internal decoder
67 .type = CX88_VMUX_DEBUG,
69 .gpio0 = 0xff01, // mono from tuner chip
71 .type = CX88_VMUX_COMPOSITE1,
75 .type = CX88_VMUX_SVIDEO,
85 .name = "GDI Black Gold",
88 .tuner_addr = ADDR_UNSET,
89 .radio_addr = ADDR_UNSET,
91 .type = CX88_VMUX_TELEVISION,
94 .type = CX88_VMUX_SVIDEO,
98 [CX88_BOARD_PIXELVIEW] = {
100 .tuner_type = TUNER_PHILIPS_PAL,
102 .tuner_addr = ADDR_UNSET,
103 .radio_addr = ADDR_UNSET,
105 .type = CX88_VMUX_TELEVISION,
107 .gpio0 = 0xff00, // internal decoder
109 .type = CX88_VMUX_COMPOSITE1,
112 .type = CX88_VMUX_SVIDEO,
120 [CX88_BOARD_ATI_WONDER_PRO] = {
121 .name = "ATI TV Wonder Pro",
122 .tuner_type = TUNER_PHILIPS_4IN1,
124 .tuner_addr = ADDR_UNSET,
125 .radio_addr = ADDR_UNSET,
126 .tda9887_conf = TDA9887_PRESENT | TDA9887_INTERCARRIER,
128 .type = CX88_VMUX_TELEVISION,
132 .type = CX88_VMUX_COMPOSITE1,
136 .type = CX88_VMUX_SVIDEO,
141 [CX88_BOARD_WINFAST2000XP_EXPERT] = {
142 .name = "Leadtek Winfast 2000XP Expert",
143 .tuner_type = TUNER_PHILIPS_4IN1,
145 .tuner_addr = ADDR_UNSET,
146 .radio_addr = ADDR_UNSET,
147 .tda9887_conf = TDA9887_PRESENT,
149 .type = CX88_VMUX_TELEVISION,
156 .type = CX88_VMUX_COMPOSITE1,
163 .type = CX88_VMUX_SVIDEO,
178 [CX88_BOARD_AVERTV_303] = {
179 .name = "AverTV Studio 303 (M126)",
180 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
182 .tuner_addr = ADDR_UNSET,
183 .radio_addr = ADDR_UNSET,
184 .tda9887_conf = TDA9887_PRESENT,
186 .type = CX88_VMUX_TELEVISION,
190 .type = CX88_VMUX_COMPOSITE1,
194 .type = CX88_VMUX_SVIDEO,
202 [CX88_BOARD_MSI_TVANYWHERE_MASTER] = {
203 // added gpio values thanks to Michal
204 // values for PAL from DScaler
205 .name = "MSI TV-@nywhere Master",
206 .tuner_type = TUNER_MT2032,
208 .tuner_addr = ADDR_UNSET,
209 .radio_addr = ADDR_UNSET,
210 .tda9887_conf = TDA9887_PRESENT,
212 .type = CX88_VMUX_TELEVISION,
218 .type = CX88_VMUX_COMPOSITE1,
224 .type = CX88_VMUX_SVIDEO,
234 [CX88_BOARD_WINFAST_DV2000] = {
235 .name = "Leadtek Winfast DV2000",
236 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
238 .tuner_addr = ADDR_UNSET,
239 .radio_addr = ADDR_UNSET,
240 .tda9887_conf = TDA9887_PRESENT,
242 .type = CX88_VMUX_TELEVISION,
250 .type = CX88_VMUX_COMPOSITE1,
257 .type = CX88_VMUX_SVIDEO,
272 [CX88_BOARD_LEADTEK_PVR2000] = {
273 // gpio values for PAL version from regspy by DScaler
274 .name = "Leadtek PVR 2000",
275 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
277 .tuner_addr = ADDR_UNSET,
278 .radio_addr = ADDR_UNSET,
279 .tda9887_conf = TDA9887_PRESENT,
281 .type = CX88_VMUX_TELEVISION,
285 .type = CX88_VMUX_COMPOSITE1,
289 .type = CX88_VMUX_SVIDEO,
299 [CX88_BOARD_IODATA_GVVCP3PCI] = {
300 .name = "IODATA GV-VCP3/PCI",
301 .tuner_type = TUNER_ABSENT,
303 .tuner_addr = ADDR_UNSET,
304 .radio_addr = ADDR_UNSET,
306 .type = CX88_VMUX_COMPOSITE1,
309 .type = CX88_VMUX_COMPOSITE2,
312 .type = CX88_VMUX_SVIDEO,
316 [CX88_BOARD_PROLINK_PLAYTVPVR] = {
317 .name = "Prolink PlayTV PVR",
318 .tuner_type = TUNER_PHILIPS_FM1236_MK3,
320 .tuner_addr = ADDR_UNSET,
321 .radio_addr = ADDR_UNSET,
322 .tda9887_conf = TDA9887_PRESENT,
324 .type = CX88_VMUX_TELEVISION,
328 .type = CX88_VMUX_COMPOSITE1,
332 .type = CX88_VMUX_SVIDEO,
341 [CX88_BOARD_ASUS_PVR_416] = {
342 .name = "ASUS PVR-416",
343 .tuner_type = TUNER_PHILIPS_FM1236_MK3,
345 .tuner_addr = ADDR_UNSET,
346 .radio_addr = ADDR_UNSET,
347 .tda9887_conf = TDA9887_PRESENT,
349 .type = CX88_VMUX_TELEVISION,
353 .type = CX88_VMUX_SVIDEO,
355 .gpio0 = 0x0000fde6, // 0x0000fda6 L,R RCA audio in?
363 [CX88_BOARD_MSI_TVANYWHERE] = {
364 .name = "MSI TV-@nywhere",
365 .tuner_type = TUNER_MT2032,
367 .tuner_addr = ADDR_UNSET,
368 .radio_addr = ADDR_UNSET,
369 .tda9887_conf = TDA9887_PRESENT,
371 .type = CX88_VMUX_TELEVISION,
376 .type = CX88_VMUX_COMPOSITE1,
381 .type = CX88_VMUX_SVIDEO,
387 [CX88_BOARD_KWORLD_DVB_T] = {
388 .name = "KWorld/VStream XPert DVB-T",
389 .tuner_type = TUNER_ABSENT,
391 .tuner_addr = ADDR_UNSET,
392 .radio_addr = ADDR_UNSET,
394 .type = CX88_VMUX_COMPOSITE1,
399 .type = CX88_VMUX_SVIDEO,
406 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1] = {
407 .name = "DViCO FusionHDTV DVB-T1",
408 .tuner_type = TUNER_ABSENT, /* No analog tuner */
410 .tuner_addr = ADDR_UNSET,
411 .radio_addr = ADDR_UNSET,
413 .type = CX88_VMUX_COMPOSITE1,
417 .type = CX88_VMUX_SVIDEO,
423 [CX88_BOARD_KWORLD_LTV883] = {
424 .name = "KWorld LTV883RF",
425 .tuner_type = TUNER_TNF_8831BGFF,
427 .tuner_addr = ADDR_UNSET,
428 .radio_addr = ADDR_UNSET,
430 .type = CX88_VMUX_TELEVISION,
434 .type = CX88_VMUX_DEBUG,
436 .gpio0 = 0x07f9, // mono from tuner chip
438 .type = CX88_VMUX_COMPOSITE1,
442 .type = CX88_VMUX_SVIDEO,
451 [CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q] = {
452 .name = "DViCO FusionHDTV 3 Gold-Q",
453 .tuner_type = TUNER_MICROTUNE_4042FI5,
455 .tuner_addr = ADDR_UNSET,
456 .radio_addr = ADDR_UNSET,
458 GPIO[0] resets DT3302 DTV receiver
461 GPIO[1] mutes analog audio output connector
462 0 - enable selected source
464 GPIO[2] selects source for analog audio output connector
465 0 - analog audio input connector on tab
466 1 - analog DAC output from CX23881 chip
467 GPIO[3] selects RF input connector on tuner module
468 0 - RF connector labeled CABLE
469 1 - RF connector labeled ANT
470 GPIO[4] selects high RF for QAM256 mode
475 .type = CX88_VMUX_TELEVISION,
479 .type = CX88_VMUX_CABLE,
483 .type = CX88_VMUX_COMPOSITE1,
487 .type = CX88_VMUX_SVIDEO,
493 [CX88_BOARD_HAUPPAUGE_DVB_T1] = {
494 .name = "Hauppauge Nova-T DVB-T",
495 .tuner_type = TUNER_ABSENT,
497 .tuner_addr = ADDR_UNSET,
498 .radio_addr = ADDR_UNSET,
500 .type = CX88_VMUX_DVB,
503 .type = CX88_VMUX_SVIDEO,
508 [CX88_BOARD_CONEXANT_DVB_T1] = {
509 .name = "Conexant DVB-T reference design",
510 .tuner_type = TUNER_ABSENT,
512 .tuner_addr = ADDR_UNSET,
513 .radio_addr = ADDR_UNSET,
515 .type = CX88_VMUX_DVB,
520 [CX88_BOARD_PROVIDEO_PV259] = {
521 .name = "Provideo PV259",
522 .tuner_type = TUNER_PHILIPS_FQ1216ME,
524 .tuner_addr = ADDR_UNSET,
525 .radio_addr = ADDR_UNSET,
527 .type = CX88_VMUX_TELEVISION,
532 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS] = {
533 .name = "DViCO FusionHDTV DVB-T Plus",
534 .tuner_type = TUNER_ABSENT, /* No analog tuner */
536 .tuner_addr = ADDR_UNSET,
537 .radio_addr = ADDR_UNSET,
539 .type = CX88_VMUX_COMPOSITE1,
543 .type = CX88_VMUX_SVIDEO,
549 [CX88_BOARD_DNTV_LIVE_DVB_T] = {
550 .name = "digitalnow DNTV Live! DVB-T",
551 .tuner_type = TUNER_ABSENT,
553 .tuner_addr = ADDR_UNSET,
554 .radio_addr = ADDR_UNSET,
556 .type = CX88_VMUX_COMPOSITE1,
561 .type = CX88_VMUX_SVIDEO,
568 [CX88_BOARD_PCHDTV_HD3000] = {
569 .name = "pcHDTV HD3000 HDTV",
570 .tuner_type = TUNER_THOMSON_DTT7610,
572 .tuner_addr = ADDR_UNSET,
573 .radio_addr = ADDR_UNSET,
575 .type = CX88_VMUX_TELEVISION,
582 .type = CX88_VMUX_COMPOSITE1,
589 .type = CX88_VMUX_SVIDEO,
606 [CX88_BOARD_HAUPPAUGE_ROSLYN] = {
607 // entry added by Kaustubh D. Bhalerao <bhalerao.1@osu.edu>
608 // GPIO values obtained from regspy, courtesy Sean Covel
609 .name = "Hauppauge WinTV 28xxx (Roslyn) models",
612 .tuner_addr = ADDR_UNSET,
613 .radio_addr = ADDR_UNSET,
615 .type = CX88_VMUX_TELEVISION,
617 .gpio0 = 0xed12, // internal decoder
620 .type = CX88_VMUX_DEBUG,
622 .gpio0 = 0xff01, // mono from tuner chip
624 .type = CX88_VMUX_COMPOSITE1,
628 .type = CX88_VMUX_SVIDEO,
640 [CX88_BOARD_DIGITALLOGIC_MEC] = {
641 .name = "Digital-Logic MICROSPACE Entertainment Center (MEC)",
642 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
644 .tuner_addr = ADDR_UNSET,
645 .radio_addr = ADDR_UNSET,
646 .tda9887_conf = TDA9887_PRESENT,
648 .type = CX88_VMUX_TELEVISION,
652 .type = CX88_VMUX_COMPOSITE1,
656 .type = CX88_VMUX_SVIDEO,
666 [CX88_BOARD_IODATA_GVBCTV7E] = {
667 .name = "IODATA GV/BCTV7E",
668 .tuner_type = TUNER_PHILIPS_FQ1286,
670 .tuner_addr = ADDR_UNSET,
671 .radio_addr = ADDR_UNSET,
672 .tda9887_conf = TDA9887_PRESENT,
674 .type = CX88_VMUX_TELEVISION,
678 .type = CX88_VMUX_COMPOSITE1,
682 .type = CX88_VMUX_SVIDEO,
687 [CX88_BOARD_PIXELVIEW_PLAYTV_ULTRA_PRO] = {
688 .name = "PixelView PlayTV Ultra Pro (Stereo)",
689 /* May be also TUNER_YMEC_TVF_5533MF for NTSC/M or PAL/M */
690 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
692 .tuner_addr = ADDR_UNSET,
693 .radio_addr = ADDR_UNSET,
695 .type = CX88_VMUX_TELEVISION,
697 .gpio0 = 0xbf61, /* internal decoder */
699 .type = CX88_VMUX_COMPOSITE1,
703 .type = CX88_VMUX_SVIDEO,
712 [CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_T] = {
713 .name = "DViCO FusionHDTV 3 Gold-T",
714 .tuner_type = TUNER_THOMSON_DTT7611,
716 .tuner_addr = ADDR_UNSET,
717 .radio_addr = ADDR_UNSET,
718 /* See DViCO FusionHDTV 3 Gold-Q for GPIO documentation. */
720 .type = CX88_VMUX_TELEVISION,
724 .type = CX88_VMUX_COMPOSITE1,
728 .type = CX88_VMUX_SVIDEO,
734 [CX88_BOARD_ADSTECH_DVB_T_PCI] = {
735 .name = "ADS Tech Instant TV DVB-T PCI",
736 .tuner_type = TUNER_ABSENT,
738 .tuner_addr = ADDR_UNSET,
739 .radio_addr = ADDR_UNSET,
741 .type = CX88_VMUX_COMPOSITE1,
746 .type = CX88_VMUX_SVIDEO,
753 [CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1] = {
754 .name = "TerraTec Cinergy 1400 DVB-T",
755 .tuner_type = TUNER_ABSENT,
757 .type = CX88_VMUX_DVB,
762 [CX88_BOARD_DVICO_FUSIONHDTV_5_GOLD] = {
763 .name = "DViCO FusionHDTV 5 Gold",
764 .tuner_type = TUNER_LG_TDVS_H062F,
766 .tuner_addr = ADDR_UNSET,
767 .radio_addr = ADDR_UNSET,
768 /* See DViCO FusionHDTV 3 Gold-Q for GPIO documentation. */
770 .type = CX88_VMUX_TELEVISION,
774 .type = CX88_VMUX_COMPOSITE1,
778 .type = CX88_VMUX_SVIDEO,
784 const unsigned int cx88_bcount = ARRAY_SIZE(cx88_boards);
786 /* ------------------------------------------------------------------ */
787 /* PCI subsystem IDs */
789 struct cx88_subid cx88_subids[] = {
793 .card = CX88_BOARD_HAUPPAUGE,
797 .card = CX88_BOARD_HAUPPAUGE,
801 .card = CX88_BOARD_GDI,
804 .subdevice = 0x0107, /* with mpeg encoder */
805 .card = CX88_BOARD_GDI,
807 .subvendor = PCI_VENDOR_ID_ATI,
809 .card = CX88_BOARD_ATI_WONDER_PRO,
813 .card = CX88_BOARD_WINFAST2000XP_EXPERT,
816 .subdevice = 0x6613, /* NTSC */
817 .card = CX88_BOARD_WINFAST2000XP_EXPERT,
821 .card = CX88_BOARD_WINFAST_DV2000,
825 .card = CX88_BOARD_LEADTEK_PVR2000,
829 .card = CX88_BOARD_LEADTEK_PVR2000,
833 .card = CX88_BOARD_AVERTV_303,
837 .card = CX88_BOARD_MSI_TVANYWHERE_MASTER,
841 .card = CX88_BOARD_IODATA_GVVCP3PCI,
844 .subdevice = 0x4823, /* with mpeg encoder */
845 .card = CX88_BOARD_ASUS_PVR_416,
849 .card = CX88_BOARD_KWORLD_DVB_T,
853 .card = CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q,
857 .card = CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_T,
861 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1,
865 .card = CX88_BOARD_HAUPPAUGE_DVB_T1,
869 .card = CX88_BOARD_CONEXANT_DVB_T1,
873 .card = CX88_BOARD_PROVIDEO_PV259,
877 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS,
881 .card = CX88_BOARD_PIXELVIEW,
884 .subdevice = 0x3000, /* HD-3000 card */
885 .card = CX88_BOARD_PCHDTV_HD3000,
889 .card = CX88_BOARD_DNTV_LIVE_DVB_T,
893 .card = CX88_BOARD_HAUPPAUGE_ROSLYN,
897 .card = CX88_BOARD_DIGITALLOGIC_MEC,
901 .card = CX88_BOARD_IODATA_GVBCTV7E,
905 .card = CX88_BOARD_ADSTECH_DVB_T_PCI,
909 .card = CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1,
913 .card = CX88_BOARD_DVICO_FUSIONHDTV_5_GOLD,
916 const unsigned int cx88_idcount = ARRAY_SIZE(cx88_subids);
918 /* ----------------------------------------------------------------------- */
919 /* some leadtek specific stuff */
921 static void __devinit leadtek_eeprom(struct cx88_core *core, u8 *eeprom_data)
923 /* This is just for the "Winfast 2000XP Expert" board ATM; I don't have data on
926 * Byte 0 is 1 on the NTSC board.
929 if (eeprom_data[4] != 0x7d ||
930 eeprom_data[5] != 0x10 ||
931 eeprom_data[7] != 0x66) {
932 printk(KERN_WARNING "%s: Leadtek eeprom invalid.\n",
938 core->tuner_type = (eeprom_data[6] == 0x13) ? 43 : 38;
940 printk(KERN_INFO "%s: Leadtek Winfast 2000XP Expert config: "
941 "tuner=%d, eeprom[0]=0x%02x\n",
942 core->name, core->tuner_type, eeprom_data[0]);
946 /* ----------------------------------------------------------------------- */
948 static void hauppauge_eeprom(struct cx88_core *core, u8 *eeprom_data)
952 tveeprom_hauppauge_analog(&tv, eeprom_data);
953 core->tuner_type = tv.tuner_type;
954 core->has_radio = tv.has_radio;
957 static int hauppauge_eeprom_dvb(struct cx88_core *core, u8 *ee)
962 /* Make sure we support the board model */
963 model = ee[0x1f] << 24 | ee[0x1e] << 16 | ee[0x1d] << 8 | ee[0x1c];
971 printk("%s: warning: unknown hauppauge model #%d\n",
976 /* Make sure we support the tuner */
979 case 0x4B: /* dtt 7595 */
980 case 0x4C: /* dtt 7592 */
983 printk("%s: error: unknown hauppauge tuner 0x%02x\n",
987 printk(KERN_INFO "%s: hauppauge eeprom: model=%d, tuner=%d\n",
988 core->name, model, tuner);
992 /* ----------------------------------------------------------------------- */
993 /* some GDI (was: Modular Technology) specific stuff */
1000 [ 0x01 ] = { .id = TUNER_ABSENT,
1002 [ 0x02 ] = { .id = TUNER_ABSENT,
1004 [ 0x03 ] = { .id = TUNER_ABSENT,
1006 [ 0x04 ] = { .id = TUNER_ABSENT,
1008 [ 0x05 ] = { .id = TUNER_ABSENT,
1011 [ 0x10 ] = { .id = TUNER_ABSENT,
1013 .name = "TEMIC_4049" },
1014 [ 0x11 ] = { .id = TUNER_TEMIC_4136FY5,
1015 .name = "TEMIC_4136" },
1016 [ 0x12 ] = { .id = TUNER_ABSENT,
1017 .name = "TEMIC_4146" },
1019 [ 0x20 ] = { .id = TUNER_PHILIPS_FQ1216ME,
1021 .name = "PHILIPS_FQ1216_MK3" },
1022 [ 0x21 ] = { .id = TUNER_ABSENT, .fm = 1,
1023 .name = "PHILIPS_FQ1236_MK3" },
1024 [ 0x22 ] = { .id = TUNER_ABSENT,
1025 .name = "PHILIPS_FI1236_MK3" },
1026 [ 0x23 ] = { .id = TUNER_ABSENT,
1027 .name = "PHILIPS_FI1216_MK3" },
1030 static void gdi_eeprom(struct cx88_core *core, u8 *eeprom_data)
1032 char *name = (eeprom_data[0x0d] < ARRAY_SIZE(gdi_tuner))
1033 ? gdi_tuner[eeprom_data[0x0d]].name : NULL;
1035 printk(KERN_INFO "%s: GDI: tuner=%s\n", core->name,
1036 name ? name : "unknown");
1039 core->tuner_type = gdi_tuner[eeprom_data[0x0d]].id;
1040 core->has_radio = gdi_tuner[eeprom_data[0x0d]].fm;
1043 /* ----------------------------------------------------------------------- */
1045 void cx88_card_list(struct cx88_core *core, struct pci_dev *pci)
1049 if (0 == pci->subsystem_vendor &&
1050 0 == pci->subsystem_device) {
1051 printk("%s: Your board has no valid PCI Subsystem ID and thus can't\n"
1052 "%s: be autodetected. Please pass card=<n> insmod option to\n"
1053 "%s: workaround that. Redirect complaints to the vendor of\n"
1054 "%s: the TV card. Best regards,\n"
1056 core->name,core->name,core->name,core->name,core->name);
1058 printk("%s: Your board isn't known (yet) to the driver. You can\n"
1059 "%s: try to pick one of the existing card configs via\n"
1060 "%s: card=<n> insmod option. Updating to the latest\n"
1061 "%s: version might help as well.\n",
1062 core->name,core->name,core->name,core->name);
1064 printk("%s: Here is a list of valid choices for the card=<n> insmod option:\n",
1066 for (i = 0; i < cx88_bcount; i++)
1067 printk("%s: card=%d -> %s\n",
1068 core->name, i, cx88_boards[i].name);
1071 void cx88_card_setup(struct cx88_core *core)
1073 static u8 eeprom[128];
1075 if (0 == core->i2c_rc) {
1076 core->i2c_client.addr = 0xa0 >> 1;
1077 tveeprom_read(&core->i2c_client,eeprom,sizeof(eeprom));
1080 switch (core->board) {
1081 case CX88_BOARD_HAUPPAUGE:
1082 case CX88_BOARD_HAUPPAUGE_ROSLYN:
1083 if (0 == core->i2c_rc)
1084 hauppauge_eeprom(core,eeprom+8);
1086 case CX88_BOARD_GDI:
1087 if (0 == core->i2c_rc)
1088 gdi_eeprom(core,eeprom);
1090 case CX88_BOARD_WINFAST2000XP_EXPERT:
1091 if (0 == core->i2c_rc)
1092 leadtek_eeprom(core,eeprom);
1094 case CX88_BOARD_HAUPPAUGE_DVB_T1:
1095 if (0 == core->i2c_rc)
1096 hauppauge_eeprom_dvb(core,eeprom);
1098 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1:
1099 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS:
1100 /* GPIO0:0 is hooked to mt352 reset pin */
1101 cx_set(MO_GP0_IO, 0x00000101);
1102 cx_clear(MO_GP0_IO, 0x00000001);
1104 cx_set(MO_GP0_IO, 0x00000101);
1106 case CX88_BOARD_KWORLD_DVB_T:
1107 case CX88_BOARD_DNTV_LIVE_DVB_T:
1108 cx_set(MO_GP0_IO, 0x00000707);
1109 cx_set(MO_GP2_IO, 0x00000101);
1110 cx_clear(MO_GP2_IO, 0x00000001);
1112 cx_clear(MO_GP0_IO, 0x00000007);
1113 cx_set(MO_GP2_IO, 0x00000101);
1116 if (cx88_boards[core->board].radio.type == CX88_RADIO)
1117 core->has_radio = 1;
1120 /* ------------------------------------------------------------------ */
1122 EXPORT_SYMBOL(cx88_boards);
1123 EXPORT_SYMBOL(cx88_bcount);
1124 EXPORT_SYMBOL(cx88_subids);
1125 EXPORT_SYMBOL(cx88_idcount);
1126 EXPORT_SYMBOL(cx88_card_list);
1127 EXPORT_SYMBOL(cx88_card_setup);
1133 * kate: eol "unix"; indent-width 3; remove-trailing-space on; replace-trailing-space-save on; tab-width 8; replace-tabs off; space-indent off; mixed-indent off