GUI: Fix Tomato RAF theme for all builds. Compilation typo.
[tomato.git] / release / src-rt-6.x.4708 / linux / linux-2.6.36 / drivers / media / video / cx88 / cx88-cards.c
blobf64992b3e1549d7fe3390a5a07bfdc22bbfbdc89
1 /*
3 * device driver for Conexant 2388x based TV cards
4 * card-specific stuff.
6 * (c) 2003 Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23 #include <linux/init.h>
24 #include <linux/module.h>
25 #include <linux/pci.h>
26 #include <linux/delay.h>
27 #include <linux/slab.h>
29 #include "cx88.h"
30 #include "tea5767.h"
32 static unsigned int tuner[] = {[0 ... (CX88_MAXBOARDS - 1)] = UNSET };
33 static unsigned int radio[] = {[0 ... (CX88_MAXBOARDS - 1)] = UNSET };
34 static unsigned int card[] = {[0 ... (CX88_MAXBOARDS - 1)] = UNSET };
36 module_param_array(tuner, int, NULL, 0444);
37 module_param_array(radio, int, NULL, 0444);
38 module_param_array(card, int, NULL, 0444);
40 MODULE_PARM_DESC(tuner,"tuner type");
41 MODULE_PARM_DESC(radio,"radio tuner type");
42 MODULE_PARM_DESC(card,"card type");
44 static unsigned int latency = UNSET;
45 module_param(latency,int,0444);
46 MODULE_PARM_DESC(latency,"pci latency timer");
48 static int disable_ir;
49 module_param(disable_ir, int, 0444);
50 MODULE_PARM_DESC(latency, "Disable IR support");
52 #define info_printk(core, fmt, arg...) \
53 printk(KERN_INFO "%s: " fmt, core->name , ## arg)
55 #define warn_printk(core, fmt, arg...) \
56 printk(KERN_WARNING "%s: " fmt, core->name , ## arg)
58 #define err_printk(core, fmt, arg...) \
59 printk(KERN_ERR "%s: " fmt, core->name , ## arg)
62 /* ------------------------------------------------------------------ */
63 /* board config info */
65 /* If radio_type !=UNSET, radio_addr should be specified
68 static const struct cx88_board cx88_boards[] = {
69 [CX88_BOARD_UNKNOWN] = {
70 .name = "UNKNOWN/GENERIC",
71 .tuner_type = UNSET,
72 .radio_type = UNSET,
73 .tuner_addr = ADDR_UNSET,
74 .radio_addr = ADDR_UNSET,
75 .input = {{
76 .type = CX88_VMUX_COMPOSITE1,
77 .vmux = 0,
78 },{
79 .type = CX88_VMUX_COMPOSITE2,
80 .vmux = 1,
81 },{
82 .type = CX88_VMUX_COMPOSITE3,
83 .vmux = 2,
84 },{
85 .type = CX88_VMUX_COMPOSITE4,
86 .vmux = 3,
87 }},
89 [CX88_BOARD_HAUPPAUGE] = {
90 .name = "Hauppauge WinTV 34xxx models",
91 .tuner_type = UNSET,
92 .radio_type = UNSET,
93 .tuner_addr = ADDR_UNSET,
94 .radio_addr = ADDR_UNSET,
95 .tda9887_conf = TDA9887_PRESENT,
96 .input = {{
97 .type = CX88_VMUX_TELEVISION,
98 .vmux = 0,
99 .gpio0 = 0xff00, // internal decoder
101 .type = CX88_VMUX_DEBUG,
102 .vmux = 0,
103 .gpio0 = 0xff01, // mono from tuner chip
105 .type = CX88_VMUX_COMPOSITE1,
106 .vmux = 1,
107 .gpio0 = 0xff02,
109 .type = CX88_VMUX_SVIDEO,
110 .vmux = 2,
111 .gpio0 = 0xff02,
113 .radio = {
114 .type = CX88_RADIO,
115 .gpio0 = 0xff01,
118 [CX88_BOARD_GDI] = {
119 .name = "GDI Black Gold",
120 .tuner_type = UNSET,
121 .radio_type = UNSET,
122 .tuner_addr = ADDR_UNSET,
123 .radio_addr = ADDR_UNSET,
124 .input = {{
125 .type = CX88_VMUX_TELEVISION,
126 .vmux = 0,
128 .type = CX88_VMUX_SVIDEO,
129 .vmux = 2,
132 [CX88_BOARD_PIXELVIEW] = {
133 .name = "PixelView",
134 .tuner_type = TUNER_PHILIPS_PAL,
135 .radio_type = UNSET,
136 .tuner_addr = ADDR_UNSET,
137 .radio_addr = ADDR_UNSET,
138 .input = {{
139 .type = CX88_VMUX_TELEVISION,
140 .vmux = 0,
141 .gpio0 = 0xff00, // internal decoder
143 .type = CX88_VMUX_COMPOSITE1,
144 .vmux = 1,
146 .type = CX88_VMUX_SVIDEO,
147 .vmux = 2,
149 .radio = {
150 .type = CX88_RADIO,
151 .gpio0 = 0xff10,
154 [CX88_BOARD_ATI_WONDER_PRO] = {
155 .name = "ATI TV Wonder Pro",
156 .tuner_type = TUNER_PHILIPS_4IN1,
157 .radio_type = UNSET,
158 .tuner_addr = ADDR_UNSET,
159 .radio_addr = ADDR_UNSET,
160 .tda9887_conf = TDA9887_PRESENT | TDA9887_INTERCARRIER,
161 .input = {{
162 .type = CX88_VMUX_TELEVISION,
163 .vmux = 0,
164 .gpio0 = 0x03ff,
166 .type = CX88_VMUX_COMPOSITE1,
167 .vmux = 1,
168 .gpio0 = 0x03fe,
170 .type = CX88_VMUX_SVIDEO,
171 .vmux = 2,
172 .gpio0 = 0x03fe,
175 [CX88_BOARD_WINFAST2000XP_EXPERT] = {
176 .name = "Leadtek Winfast 2000XP Expert",
177 .tuner_type = TUNER_PHILIPS_4IN1,
178 .radio_type = UNSET,
179 .tuner_addr = ADDR_UNSET,
180 .radio_addr = ADDR_UNSET,
181 .tda9887_conf = TDA9887_PRESENT,
182 .input = {{
183 .type = CX88_VMUX_TELEVISION,
184 .vmux = 0,
185 .gpio0 = 0x00F5e700,
186 .gpio1 = 0x00003004,
187 .gpio2 = 0x00F5e700,
188 .gpio3 = 0x02000000,
190 .type = CX88_VMUX_COMPOSITE1,
191 .vmux = 1,
192 .gpio0 = 0x00F5c700,
193 .gpio1 = 0x00003004,
194 .gpio2 = 0x00F5c700,
195 .gpio3 = 0x02000000,
197 .type = CX88_VMUX_SVIDEO,
198 .vmux = 2,
199 .gpio0 = 0x00F5c700,
200 .gpio1 = 0x00003004,
201 .gpio2 = 0x00F5c700,
202 .gpio3 = 0x02000000,
204 .radio = {
205 .type = CX88_RADIO,
206 .gpio0 = 0x00F5d700,
207 .gpio1 = 0x00003004,
208 .gpio2 = 0x00F5d700,
209 .gpio3 = 0x02000000,
212 [CX88_BOARD_AVERTV_STUDIO_303] = {
213 .name = "AverTV Studio 303 (M126)",
214 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
215 .radio_type = UNSET,
216 .tuner_addr = ADDR_UNSET,
217 .radio_addr = ADDR_UNSET,
218 .tda9887_conf = TDA9887_PRESENT,
219 .input = {{
220 .type = CX88_VMUX_TELEVISION,
221 .vmux = 0,
222 .gpio1 = 0xe09f,
224 .type = CX88_VMUX_COMPOSITE1,
225 .vmux = 1,
226 .gpio1 = 0xe05f,
228 .type = CX88_VMUX_SVIDEO,
229 .vmux = 2,
230 .gpio1 = 0xe05f,
232 .radio = {
233 .gpio1 = 0xe0df,
234 .type = CX88_RADIO,
237 [CX88_BOARD_MSI_TVANYWHERE_MASTER] = {
238 // added gpio values thanks to Michal
239 // values for PAL from DScaler
240 .name = "MSI TV-@nywhere Master",
241 .tuner_type = TUNER_MT2032,
242 .radio_type = UNSET,
243 .tuner_addr = ADDR_UNSET,
244 .radio_addr = ADDR_UNSET,
245 .tda9887_conf = TDA9887_PRESENT | TDA9887_INTERCARRIER_NTSC,
246 .input = {{
247 .type = CX88_VMUX_TELEVISION,
248 .vmux = 0,
249 .gpio0 = 0x000040bf,
250 .gpio1 = 0x000080c0,
251 .gpio2 = 0x0000ff40,
253 .type = CX88_VMUX_COMPOSITE1,
254 .vmux = 1,
255 .gpio0 = 0x000040bf,
256 .gpio1 = 0x000080c0,
257 .gpio2 = 0x0000ff40,
259 .type = CX88_VMUX_SVIDEO,
260 .vmux = 2,
261 .gpio0 = 0x000040bf,
262 .gpio1 = 0x000080c0,
263 .gpio2 = 0x0000ff40,
265 .radio = {
266 .type = CX88_RADIO,
267 .vmux = 3,
268 .gpio0 = 0x000040bf,
269 .gpio1 = 0x000080c0,
270 .gpio2 = 0x0000ff20,
273 [CX88_BOARD_WINFAST_DV2000] = {
274 .name = "Leadtek Winfast DV2000",
275 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
276 .radio_type = UNSET,
277 .tuner_addr = ADDR_UNSET,
278 .radio_addr = ADDR_UNSET,
279 .tda9887_conf = TDA9887_PRESENT,
280 .input = {{
281 .type = CX88_VMUX_TELEVISION,
282 .vmux = 0,
283 .gpio0 = 0x0035e700,
284 .gpio1 = 0x00003004,
285 .gpio2 = 0x0035e700,
286 .gpio3 = 0x02000000,
289 .type = CX88_VMUX_COMPOSITE1,
290 .vmux = 1,
291 .gpio0 = 0x0035c700,
292 .gpio1 = 0x00003004,
293 .gpio2 = 0x0035c700,
294 .gpio3 = 0x02000000,
296 .type = CX88_VMUX_SVIDEO,
297 .vmux = 2,
298 .gpio0 = 0x0035c700,
299 .gpio1 = 0x0035c700,
300 .gpio2 = 0x02000000,
301 .gpio3 = 0x02000000,
303 .radio = {
304 .type = CX88_RADIO,
305 .gpio0 = 0x0035d700,
306 .gpio1 = 0x00007004,
307 .gpio2 = 0x0035d700,
308 .gpio3 = 0x02000000,
311 [CX88_BOARD_LEADTEK_PVR2000] = {
312 // gpio values for PAL version from regspy by DScaler
313 .name = "Leadtek PVR 2000",
314 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
315 .radio_type = UNSET,
316 .tuner_addr = ADDR_UNSET,
317 .radio_addr = ADDR_UNSET,
318 .tda9887_conf = TDA9887_PRESENT,
319 .input = {{
320 .type = CX88_VMUX_TELEVISION,
321 .vmux = 0,
322 .gpio0 = 0x0000bde2,
323 .audioroute = 1,
325 .type = CX88_VMUX_COMPOSITE1,
326 .vmux = 1,
327 .gpio0 = 0x0000bde6,
328 .audioroute = 1,
330 .type = CX88_VMUX_SVIDEO,
331 .vmux = 2,
332 .gpio0 = 0x0000bde6,
333 .audioroute = 1,
335 .radio = {
336 .type = CX88_RADIO,
337 .gpio0 = 0x0000bd62,
338 .audioroute = 1,
340 .mpeg = CX88_MPEG_BLACKBIRD,
342 [CX88_BOARD_IODATA_GVVCP3PCI] = {
343 .name = "IODATA GV-VCP3/PCI",
344 .tuner_type = TUNER_ABSENT,
345 .radio_type = UNSET,
346 .tuner_addr = ADDR_UNSET,
347 .radio_addr = ADDR_UNSET,
348 .input = {{
349 .type = CX88_VMUX_COMPOSITE1,
350 .vmux = 0,
352 .type = CX88_VMUX_COMPOSITE2,
353 .vmux = 1,
355 .type = CX88_VMUX_SVIDEO,
356 .vmux = 2,
359 [CX88_BOARD_PROLINK_PLAYTVPVR] = {
360 .name = "Prolink PlayTV PVR",
361 .tuner_type = TUNER_PHILIPS_FM1236_MK3,
362 .radio_type = UNSET,
363 .tuner_addr = ADDR_UNSET,
364 .radio_addr = ADDR_UNSET,
365 .tda9887_conf = TDA9887_PRESENT,
366 .input = {{
367 .type = CX88_VMUX_TELEVISION,
368 .vmux = 0,
369 .gpio0 = 0xbff0,
371 .type = CX88_VMUX_COMPOSITE1,
372 .vmux = 1,
373 .gpio0 = 0xbff3,
375 .type = CX88_VMUX_SVIDEO,
376 .vmux = 2,
377 .gpio0 = 0xbff3,
379 .radio = {
380 .type = CX88_RADIO,
381 .gpio0 = 0xbff0,
384 [CX88_BOARD_ASUS_PVR_416] = {
385 .name = "ASUS PVR-416",
386 .tuner_type = TUNER_PHILIPS_FM1236_MK3,
387 .radio_type = UNSET,
388 .tuner_addr = ADDR_UNSET,
389 .radio_addr = ADDR_UNSET,
390 .tda9887_conf = TDA9887_PRESENT,
391 .input = {{
392 .type = CX88_VMUX_TELEVISION,
393 .vmux = 0,
394 .gpio0 = 0x0000fde6,
396 .type = CX88_VMUX_SVIDEO,
397 .vmux = 2,
398 .gpio0 = 0x0000fde6, // 0x0000fda6 L,R RCA audio in?
399 .audioroute = 1,
401 .radio = {
402 .type = CX88_RADIO,
403 .gpio0 = 0x0000fde2,
405 .mpeg = CX88_MPEG_BLACKBIRD,
407 [CX88_BOARD_MSI_TVANYWHERE] = {
408 .name = "MSI TV-@nywhere",
409 .tuner_type = TUNER_MT2032,
410 .radio_type = UNSET,
411 .tuner_addr = ADDR_UNSET,
412 .radio_addr = ADDR_UNSET,
413 .tda9887_conf = TDA9887_PRESENT,
414 .input = {{
415 .type = CX88_VMUX_TELEVISION,
416 .vmux = 0,
417 .gpio0 = 0x00000fbf,
418 .gpio2 = 0x0000fc08,
420 .type = CX88_VMUX_COMPOSITE1,
421 .vmux = 1,
422 .gpio0 = 0x00000fbf,
423 .gpio2 = 0x0000fc68,
425 .type = CX88_VMUX_SVIDEO,
426 .vmux = 2,
427 .gpio0 = 0x00000fbf,
428 .gpio2 = 0x0000fc68,
431 [CX88_BOARD_KWORLD_DVB_T] = {
432 .name = "KWorld/VStream XPert DVB-T",
433 .tuner_type = TUNER_ABSENT,
434 .radio_type = UNSET,
435 .tuner_addr = ADDR_UNSET,
436 .radio_addr = ADDR_UNSET,
437 .input = {{
438 .type = CX88_VMUX_COMPOSITE1,
439 .vmux = 1,
440 .gpio0 = 0x0700,
441 .gpio2 = 0x0101,
443 .type = CX88_VMUX_SVIDEO,
444 .vmux = 2,
445 .gpio0 = 0x0700,
446 .gpio2 = 0x0101,
448 .mpeg = CX88_MPEG_DVB,
450 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1] = {
451 .name = "DViCO FusionHDTV DVB-T1",
452 .tuner_type = TUNER_ABSENT, /* No analog tuner */
453 .radio_type = UNSET,
454 .tuner_addr = ADDR_UNSET,
455 .radio_addr = ADDR_UNSET,
456 .input = {{
457 .type = CX88_VMUX_COMPOSITE1,
458 .vmux = 1,
459 .gpio0 = 0x000027df,
461 .type = CX88_VMUX_SVIDEO,
462 .vmux = 2,
463 .gpio0 = 0x000027df,
465 .mpeg = CX88_MPEG_DVB,
467 [CX88_BOARD_KWORLD_LTV883] = {
468 .name = "KWorld LTV883RF",
469 .tuner_type = TUNER_TNF_8831BGFF,
470 .radio_type = UNSET,
471 .tuner_addr = ADDR_UNSET,
472 .radio_addr = ADDR_UNSET,
473 .input = {{
474 .type = CX88_VMUX_TELEVISION,
475 .vmux = 0,
476 .gpio0 = 0x07f8,
478 .type = CX88_VMUX_DEBUG,
479 .vmux = 0,
480 .gpio0 = 0x07f9, // mono from tuner chip
482 .type = CX88_VMUX_COMPOSITE1,
483 .vmux = 1,
484 .gpio0 = 0x000007fa,
486 .type = CX88_VMUX_SVIDEO,
487 .vmux = 2,
488 .gpio0 = 0x000007fa,
490 .radio = {
491 .type = CX88_RADIO,
492 .gpio0 = 0x000007f8,
495 [CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q] = {
496 .name = "DViCO FusionHDTV 3 Gold-Q",
497 .tuner_type = TUNER_MICROTUNE_4042FI5,
498 .radio_type = UNSET,
499 .tuner_addr = ADDR_UNSET,
500 .radio_addr = ADDR_UNSET,
502 GPIO[0] resets DT3302 DTV receiver
503 0 - reset asserted
504 1 - normal operation
505 GPIO[1] mutes analog audio output connector
506 0 - enable selected source
507 1 - mute
508 GPIO[2] selects source for analog audio output connector
509 0 - analog audio input connector on tab
510 1 - analog DAC output from CX23881 chip
511 GPIO[3] selects RF input connector on tuner module
512 0 - RF connector labeled CABLE
513 1 - RF connector labeled ANT
514 GPIO[4] selects high RF for QAM256 mode
515 0 - normal RF
516 1 - high RF
518 .input = {{
519 .type = CX88_VMUX_TELEVISION,
520 .vmux = 0,
521 .gpio0 = 0x0f0d,
523 .type = CX88_VMUX_CABLE,
524 .vmux = 0,
525 .gpio0 = 0x0f05,
527 .type = CX88_VMUX_COMPOSITE1,
528 .vmux = 1,
529 .gpio0 = 0x0f00,
531 .type = CX88_VMUX_SVIDEO,
532 .vmux = 2,
533 .gpio0 = 0x0f00,
535 .mpeg = CX88_MPEG_DVB,
537 [CX88_BOARD_HAUPPAUGE_DVB_T1] = {
538 .name = "Hauppauge Nova-T DVB-T",
539 .tuner_type = TUNER_ABSENT,
540 .radio_type = UNSET,
541 .tuner_addr = ADDR_UNSET,
542 .radio_addr = ADDR_UNSET,
543 .input = {{
544 .type = CX88_VMUX_DVB,
545 .vmux = 0,
547 .mpeg = CX88_MPEG_DVB,
549 [CX88_BOARD_CONEXANT_DVB_T1] = {
550 .name = "Conexant DVB-T reference design",
551 .tuner_type = TUNER_ABSENT,
552 .radio_type = UNSET,
553 .tuner_addr = ADDR_UNSET,
554 .radio_addr = ADDR_UNSET,
555 .input = {{
556 .type = CX88_VMUX_DVB,
557 .vmux = 0,
559 .mpeg = CX88_MPEG_DVB,
561 [CX88_BOARD_PROVIDEO_PV259] = {
562 .name = "Provideo PV259",
563 .tuner_type = TUNER_PHILIPS_FQ1216ME,
564 .radio_type = UNSET,
565 .tuner_addr = ADDR_UNSET,
566 .radio_addr = ADDR_UNSET,
567 .input = {{
568 .type = CX88_VMUX_TELEVISION,
569 .vmux = 0,
570 .audioroute = 1,
572 .mpeg = CX88_MPEG_BLACKBIRD,
574 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS] = {
575 .name = "DViCO FusionHDTV DVB-T Plus",
576 .tuner_type = TUNER_ABSENT, /* No analog tuner */
577 .radio_type = UNSET,
578 .tuner_addr = ADDR_UNSET,
579 .radio_addr = ADDR_UNSET,
580 .input = {{
581 .type = CX88_VMUX_COMPOSITE1,
582 .vmux = 1,
583 .gpio0 = 0x000027df,
585 .type = CX88_VMUX_SVIDEO,
586 .vmux = 2,
587 .gpio0 = 0x000027df,
589 .mpeg = CX88_MPEG_DVB,
591 [CX88_BOARD_DNTV_LIVE_DVB_T] = {
592 .name = "digitalnow DNTV Live! DVB-T",
593 .tuner_type = TUNER_ABSENT,
594 .radio_type = UNSET,
595 .tuner_addr = ADDR_UNSET,
596 .radio_addr = ADDR_UNSET,
597 .input = {{
598 .type = CX88_VMUX_COMPOSITE1,
599 .vmux = 1,
600 .gpio0 = 0x00000700,
601 .gpio2 = 0x00000101,
603 .type = CX88_VMUX_SVIDEO,
604 .vmux = 2,
605 .gpio0 = 0x00000700,
606 .gpio2 = 0x00000101,
608 .mpeg = CX88_MPEG_DVB,
610 [CX88_BOARD_PCHDTV_HD3000] = {
611 .name = "pcHDTV HD3000 HDTV",
612 .tuner_type = TUNER_THOMSON_DTT761X,
613 .radio_type = UNSET,
614 .tuner_addr = ADDR_UNSET,
615 .radio_addr = ADDR_UNSET,
616 .tda9887_conf = TDA9887_PRESENT,
617 /* GPIO[2] = audio source for analog audio out connector
618 * 0 = analog audio input connector
619 * 1 = CX88 audio DACs
621 * GPIO[7] = input to CX88's audio/chroma ADC
622 * 0 = FM 10.7 MHz IF
623 * 1 = Sound 4.5 MHz IF
625 * GPIO[1,5,6] = Oren 51132 pins 27,35,28 respectively
627 * GPIO[16] = Remote control input
629 .input = {{
630 .type = CX88_VMUX_TELEVISION,
631 .vmux = 0,
632 .gpio0 = 0x00008484,
634 .type = CX88_VMUX_COMPOSITE1,
635 .vmux = 1,
636 .gpio0 = 0x00008400,
638 .type = CX88_VMUX_SVIDEO,
639 .vmux = 2,
640 .gpio0 = 0x00008400,
642 .radio = {
643 .type = CX88_RADIO,
644 .gpio0 = 0x00008404,
646 .mpeg = CX88_MPEG_DVB,
648 [CX88_BOARD_HAUPPAUGE_ROSLYN] = {
649 // entry added by Kaustubh D. Bhalerao <bhalerao.1@osu.edu>
650 // GPIO values obtained from regspy, courtesy Sean Covel
651 .name = "Hauppauge WinTV 28xxx (Roslyn) models",
652 .tuner_type = UNSET,
653 .radio_type = UNSET,
654 .tuner_addr = ADDR_UNSET,
655 .radio_addr = ADDR_UNSET,
656 .input = {{
657 .type = CX88_VMUX_TELEVISION,
658 .vmux = 0,
659 .gpio0 = 0xed1a,
660 .gpio2 = 0x00ff,
662 .type = CX88_VMUX_DEBUG,
663 .vmux = 0,
664 .gpio0 = 0xff01,
666 .type = CX88_VMUX_COMPOSITE1,
667 .vmux = 1,
668 .gpio0 = 0xff02,
670 .type = CX88_VMUX_SVIDEO,
671 .vmux = 2,
672 .gpio0 = 0xed92,
673 .gpio2 = 0x00ff,
675 .radio = {
676 .type = CX88_RADIO,
677 .gpio0 = 0xed96,
678 .gpio2 = 0x00ff,
680 .mpeg = CX88_MPEG_BLACKBIRD,
682 [CX88_BOARD_DIGITALLOGIC_MEC] = {
683 .name = "Digital-Logic MICROSPACE Entertainment Center (MEC)",
684 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
685 .radio_type = UNSET,
686 .tuner_addr = ADDR_UNSET,
687 .radio_addr = ADDR_UNSET,
688 .tda9887_conf = TDA9887_PRESENT,
689 .input = {{
690 .type = CX88_VMUX_TELEVISION,
691 .vmux = 0,
692 .gpio0 = 0x00009d80,
693 .audioroute = 1,
695 .type = CX88_VMUX_COMPOSITE1,
696 .vmux = 1,
697 .gpio0 = 0x00009d76,
698 .audioroute = 1,
700 .type = CX88_VMUX_SVIDEO,
701 .vmux = 2,
702 .gpio0 = 0x00009d76,
703 .audioroute = 1,
705 .radio = {
706 .type = CX88_RADIO,
707 .gpio0 = 0x00009d00,
708 .audioroute = 1,
710 .mpeg = CX88_MPEG_BLACKBIRD,
712 [CX88_BOARD_IODATA_GVBCTV7E] = {
713 .name = "IODATA GV/BCTV7E",
714 .tuner_type = TUNER_PHILIPS_FQ1286,
715 .radio_type = UNSET,
716 .tuner_addr = ADDR_UNSET,
717 .radio_addr = ADDR_UNSET,
718 .tda9887_conf = TDA9887_PRESENT,
719 .input = {{
720 .type = CX88_VMUX_TELEVISION,
721 .vmux = 1,
722 .gpio1 = 0x0000e03f,
724 .type = CX88_VMUX_COMPOSITE1,
725 .vmux = 2,
726 .gpio1 = 0x0000e07f,
728 .type = CX88_VMUX_SVIDEO,
729 .vmux = 3,
730 .gpio1 = 0x0000e07f,
733 [CX88_BOARD_PIXELVIEW_PLAYTV_ULTRA_PRO] = {
734 .name = "PixelView PlayTV Ultra Pro (Stereo)",
735 /* May be also TUNER_YMEC_TVF_5533MF for NTSC/M or PAL/M */
736 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
737 .radio_type = UNSET,
738 .tuner_addr = ADDR_UNSET,
739 .radio_addr = ADDR_UNSET,
740 /* Some variants use a tda9874 and so need the tvaudio module. */
741 .audio_chip = V4L2_IDENT_TVAUDIO,
742 .input = {{
743 .type = CX88_VMUX_TELEVISION,
744 .vmux = 0,
745 .gpio0 = 0xbf61, /* internal decoder */
747 .type = CX88_VMUX_COMPOSITE1,
748 .vmux = 1,
749 .gpio0 = 0xbf63,
751 .type = CX88_VMUX_SVIDEO,
752 .vmux = 2,
753 .gpio0 = 0xbf63,
755 .radio = {
756 .type = CX88_RADIO,
757 .gpio0 = 0xbf60,
760 [CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_T] = {
761 .name = "DViCO FusionHDTV 3 Gold-T",
762 .tuner_type = TUNER_THOMSON_DTT761X,
763 .radio_type = UNSET,
764 .tuner_addr = ADDR_UNSET,
765 .radio_addr = ADDR_UNSET,
766 .tda9887_conf = TDA9887_PRESENT,
767 .input = {{
768 .type = CX88_VMUX_TELEVISION,
769 .vmux = 0,
770 .gpio0 = 0x97ed,
772 .type = CX88_VMUX_COMPOSITE1,
773 .vmux = 1,
774 .gpio0 = 0x97e9,
776 .type = CX88_VMUX_SVIDEO,
777 .vmux = 2,
778 .gpio0 = 0x97e9,
780 .mpeg = CX88_MPEG_DVB,
782 [CX88_BOARD_ADSTECH_DVB_T_PCI] = {
783 .name = "ADS Tech Instant TV DVB-T PCI",
784 .tuner_type = TUNER_ABSENT,
785 .radio_type = UNSET,
786 .tuner_addr = ADDR_UNSET,
787 .radio_addr = ADDR_UNSET,
788 .input = {{
789 .type = CX88_VMUX_COMPOSITE1,
790 .vmux = 1,
791 .gpio0 = 0x0700,
792 .gpio2 = 0x0101,
794 .type = CX88_VMUX_SVIDEO,
795 .vmux = 2,
796 .gpio0 = 0x0700,
797 .gpio2 = 0x0101,
799 .mpeg = CX88_MPEG_DVB,
801 [CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1] = {
802 .name = "TerraTec Cinergy 1400 DVB-T",
803 .tuner_type = TUNER_ABSENT,
804 .input = {{
805 .type = CX88_VMUX_DVB,
806 .vmux = 0,
808 .type = CX88_VMUX_COMPOSITE1,
809 .vmux = 2,
811 .type = CX88_VMUX_SVIDEO,
812 .vmux = 2,
814 .mpeg = CX88_MPEG_DVB,
816 [CX88_BOARD_DVICO_FUSIONHDTV_5_GOLD] = {
817 .name = "DViCO FusionHDTV 5 Gold",
818 .tuner_type = TUNER_LG_TDVS_H06XF, /* TDVS-H062F */
819 .radio_type = UNSET,
820 .tuner_addr = ADDR_UNSET,
821 .radio_addr = ADDR_UNSET,
822 .tda9887_conf = TDA9887_PRESENT,
823 .input = {{
824 .type = CX88_VMUX_TELEVISION,
825 .vmux = 0,
826 .gpio0 = 0x87fd,
828 .type = CX88_VMUX_COMPOSITE1,
829 .vmux = 1,
830 .gpio0 = 0x87f9,
832 .type = CX88_VMUX_SVIDEO,
833 .vmux = 2,
834 .gpio0 = 0x87f9,
836 .mpeg = CX88_MPEG_DVB,
838 [CX88_BOARD_AVERMEDIA_ULTRATV_MC_550] = {
839 .name = "AverMedia UltraTV Media Center PCI 550",
840 .tuner_type = TUNER_PHILIPS_FM1236_MK3,
841 .radio_type = UNSET,
842 .tuner_addr = ADDR_UNSET,
843 .radio_addr = ADDR_UNSET,
844 .tda9887_conf = TDA9887_PRESENT,
845 .input = {{
846 .type = CX88_VMUX_COMPOSITE1,
847 .vmux = 0,
848 .gpio0 = 0x0000cd73,
849 .audioroute = 1,
851 .type = CX88_VMUX_SVIDEO,
852 .vmux = 1,
853 .gpio0 = 0x0000cd73,
854 .audioroute = 1,
856 .type = CX88_VMUX_TELEVISION,
857 .vmux = 3,
858 .gpio0 = 0x0000cdb3,
859 .audioroute = 1,
861 .radio = {
862 .type = CX88_RADIO,
863 .vmux = 2,
864 .gpio0 = 0x0000cdf3,
865 .audioroute = 1,
867 .mpeg = CX88_MPEG_BLACKBIRD,
869 [CX88_BOARD_KWORLD_VSTREAM_EXPERT_DVD] = {
870 /* Alexander Wold <awold@bigfoot.com> */
871 .name = "Kworld V-Stream Xpert DVD",
872 .tuner_type = UNSET,
873 .input = {{
874 .type = CX88_VMUX_COMPOSITE1,
875 .vmux = 1,
876 .gpio0 = 0x03000000,
877 .gpio1 = 0x01000000,
878 .gpio2 = 0x02000000,
879 .gpio3 = 0x00100000,
881 .type = CX88_VMUX_SVIDEO,
882 .vmux = 2,
883 .gpio0 = 0x03000000,
884 .gpio1 = 0x01000000,
885 .gpio2 = 0x02000000,
886 .gpio3 = 0x00100000,
889 [CX88_BOARD_ATI_HDTVWONDER] = {
890 .name = "ATI HDTV Wonder",
891 .tuner_type = TUNER_PHILIPS_TUV1236D,
892 .radio_type = UNSET,
893 .tuner_addr = ADDR_UNSET,
894 .radio_addr = ADDR_UNSET,
895 .input = {{
896 .type = CX88_VMUX_TELEVISION,
897 .vmux = 0,
898 .gpio0 = 0x00000ff7,
899 .gpio1 = 0x000000ff,
900 .gpio2 = 0x00000001,
901 .gpio3 = 0x00000000,
903 .type = CX88_VMUX_COMPOSITE1,
904 .vmux = 1,
905 .gpio0 = 0x00000ffe,
906 .gpio1 = 0x000000ff,
907 .gpio2 = 0x00000001,
908 .gpio3 = 0x00000000,
910 .type = CX88_VMUX_SVIDEO,
911 .vmux = 2,
912 .gpio0 = 0x00000ffe,
913 .gpio1 = 0x000000ff,
914 .gpio2 = 0x00000001,
915 .gpio3 = 0x00000000,
917 .mpeg = CX88_MPEG_DVB,
919 [CX88_BOARD_WINFAST_DTV1000] = {
920 .name = "WinFast DTV1000-T",
921 .tuner_type = TUNER_ABSENT,
922 .radio_type = UNSET,
923 .tuner_addr = ADDR_UNSET,
924 .radio_addr = ADDR_UNSET,
925 .input = {{
926 .type = CX88_VMUX_DVB,
927 .vmux = 0,
929 .type = CX88_VMUX_COMPOSITE1,
930 .vmux = 1,
932 .type = CX88_VMUX_SVIDEO,
933 .vmux = 2,
935 .mpeg = CX88_MPEG_DVB,
937 [CX88_BOARD_AVERTV_303] = {
938 .name = "AVerTV 303 (M126)",
939 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
940 .radio_type = UNSET,
941 .tuner_addr = ADDR_UNSET,
942 .radio_addr = ADDR_UNSET,
943 .tda9887_conf = TDA9887_PRESENT,
944 .input = {{
945 .type = CX88_VMUX_TELEVISION,
946 .vmux = 0,
947 .gpio0 = 0x00ff,
948 .gpio1 = 0xe09f,
949 .gpio2 = 0x0010,
950 .gpio3 = 0x0000,
952 .type = CX88_VMUX_COMPOSITE1,
953 .vmux = 1,
954 .gpio0 = 0x00ff,
955 .gpio1 = 0xe05f,
956 .gpio2 = 0x0010,
957 .gpio3 = 0x0000,
959 .type = CX88_VMUX_SVIDEO,
960 .vmux = 2,
961 .gpio0 = 0x00ff,
962 .gpio1 = 0xe05f,
963 .gpio2 = 0x0010,
964 .gpio3 = 0x0000,
967 [CX88_BOARD_HAUPPAUGE_NOVASPLUS_S1] = {
968 .name = "Hauppauge Nova-S-Plus DVB-S",
969 .tuner_type = TUNER_ABSENT,
970 .radio_type = UNSET,
971 .tuner_addr = ADDR_UNSET,
972 .radio_addr = ADDR_UNSET,
973 .input = {{
974 .type = CX88_VMUX_DVB,
975 .vmux = 0,
977 .type = CX88_VMUX_COMPOSITE1,
978 .vmux = 1,
980 .type = CX88_VMUX_SVIDEO,
981 .vmux = 2,
983 .mpeg = CX88_MPEG_DVB,
985 [CX88_BOARD_HAUPPAUGE_NOVASE2_S1] = {
986 .name = "Hauppauge Nova-SE2 DVB-S",
987 .tuner_type = TUNER_ABSENT,
988 .radio_type = UNSET,
989 .tuner_addr = ADDR_UNSET,
990 .radio_addr = ADDR_UNSET,
991 .input = {{
992 .type = CX88_VMUX_DVB,
993 .vmux = 0,
995 .mpeg = CX88_MPEG_DVB,
997 [CX88_BOARD_KWORLD_DVBS_100] = {
998 .name = "KWorld DVB-S 100",
999 .tuner_type = TUNER_ABSENT,
1000 .radio_type = UNSET,
1001 .tuner_addr = ADDR_UNSET,
1002 .radio_addr = ADDR_UNSET,
1003 .input = {{
1004 .type = CX88_VMUX_DVB,
1005 .vmux = 0,
1007 .type = CX88_VMUX_COMPOSITE1,
1008 .vmux = 1,
1010 .type = CX88_VMUX_SVIDEO,
1011 .vmux = 2,
1013 .mpeg = CX88_MPEG_DVB,
1015 [CX88_BOARD_HAUPPAUGE_HVR1100] = {
1016 .name = "Hauppauge WinTV-HVR1100 DVB-T/Hybrid",
1017 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1018 .radio_type = UNSET,
1019 .tuner_addr = ADDR_UNSET,
1020 .radio_addr = ADDR_UNSET,
1021 .tda9887_conf = TDA9887_PRESENT,
1022 .input = {{
1023 .type = CX88_VMUX_TELEVISION,
1024 .vmux = 0,
1026 .type = CX88_VMUX_COMPOSITE1,
1027 .vmux = 1,
1029 .type = CX88_VMUX_SVIDEO,
1030 .vmux = 2,
1032 .mpeg = CX88_MPEG_DVB,
1034 [CX88_BOARD_HAUPPAUGE_HVR1100LP] = {
1035 .name = "Hauppauge WinTV-HVR1100 DVB-T/Hybrid (Low Profile)",
1036 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1037 .radio_type = UNSET,
1038 .tuner_addr = ADDR_UNSET,
1039 .radio_addr = ADDR_UNSET,
1040 .tda9887_conf = TDA9887_PRESENT,
1041 .input = {{
1042 .type = CX88_VMUX_TELEVISION,
1043 .vmux = 0,
1045 .type = CX88_VMUX_COMPOSITE1,
1046 .vmux = 1,
1048 .mpeg = CX88_MPEG_DVB,
1050 [CX88_BOARD_DNTV_LIVE_DVB_T_PRO] = {
1051 .name = "digitalnow DNTV Live! DVB-T Pro",
1052 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1053 .radio_type = UNSET,
1054 .tuner_addr = ADDR_UNSET,
1055 .radio_addr = ADDR_UNSET,
1056 .tda9887_conf = TDA9887_PRESENT | TDA9887_PORT1_ACTIVE |
1057 TDA9887_PORT2_ACTIVE,
1058 .input = {{
1059 .type = CX88_VMUX_TELEVISION,
1060 .vmux = 0,
1061 .gpio0 = 0xf80808,
1063 .type = CX88_VMUX_COMPOSITE1,
1064 .vmux = 1,
1065 .gpio0 = 0xf80808,
1067 .type = CX88_VMUX_SVIDEO,
1068 .vmux = 2,
1069 .gpio0 = 0xf80808,
1071 .radio = {
1072 .type = CX88_RADIO,
1073 .gpio0 = 0xf80808,
1075 .mpeg = CX88_MPEG_DVB,
1077 [CX88_BOARD_KWORLD_DVB_T_CX22702] = {
1078 /* Kworld V-stream Xpert DVB-T with Thomson tuner */
1079 /* DTT 7579 Conexant CX22702-19 Conexant CX2388x */
1080 /* Manenti Marco <marco_manenti@colman.it> */
1081 .name = "KWorld/VStream XPert DVB-T with cx22702",
1082 .tuner_type = TUNER_ABSENT,
1083 .radio_type = UNSET,
1084 .tuner_addr = ADDR_UNSET,
1085 .radio_addr = ADDR_UNSET,
1086 .input = {{
1087 .type = CX88_VMUX_COMPOSITE1,
1088 .vmux = 1,
1089 .gpio0 = 0x0700,
1090 .gpio2 = 0x0101,
1092 .type = CX88_VMUX_SVIDEO,
1093 .vmux = 2,
1094 .gpio0 = 0x0700,
1095 .gpio2 = 0x0101,
1097 .mpeg = CX88_MPEG_DVB,
1099 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL] = {
1100 .name = "DViCO FusionHDTV DVB-T Dual Digital",
1101 .tuner_type = TUNER_ABSENT, /* No analog tuner */
1102 .radio_type = UNSET,
1103 .tuner_addr = ADDR_UNSET,
1104 .radio_addr = ADDR_UNSET,
1105 .input = {{
1106 .type = CX88_VMUX_COMPOSITE1,
1107 .vmux = 1,
1108 .gpio0 = 0x000067df,
1110 .type = CX88_VMUX_SVIDEO,
1111 .vmux = 2,
1112 .gpio0 = 0x000067df,
1114 .mpeg = CX88_MPEG_DVB,
1116 [CX88_BOARD_KWORLD_HARDWARE_MPEG_TV_XPERT] = {
1117 .name = "KWorld HardwareMpegTV XPert",
1118 .tuner_type = TUNER_PHILIPS_TDA8290,
1119 .radio_type = UNSET,
1120 .tuner_addr = ADDR_UNSET,
1121 .radio_addr = ADDR_UNSET,
1122 .input = {{
1123 .type = CX88_VMUX_TELEVISION,
1124 .vmux = 0,
1125 .gpio0 = 0x3de2,
1126 .gpio2 = 0x00ff,
1128 .type = CX88_VMUX_COMPOSITE1,
1129 .vmux = 1,
1130 .gpio0 = 0x3de6,
1131 .audioroute = 1,
1133 .type = CX88_VMUX_SVIDEO,
1134 .vmux = 2,
1135 .gpio0 = 0x3de6,
1136 .audioroute = 1,
1138 .radio = {
1139 .type = CX88_RADIO,
1140 .gpio0 = 0x3de6,
1141 .gpio2 = 0x00ff,
1143 .mpeg = CX88_MPEG_BLACKBIRD,
1145 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_HYBRID] = {
1146 .name = "DViCO FusionHDTV DVB-T Hybrid",
1147 .tuner_type = TUNER_THOMSON_FE6600,
1148 .radio_type = UNSET,
1149 .tuner_addr = ADDR_UNSET,
1150 .radio_addr = ADDR_UNSET,
1151 .input = {{
1152 .type = CX88_VMUX_TELEVISION,
1153 .vmux = 0,
1154 .gpio0 = 0x0000a75f,
1156 .type = CX88_VMUX_COMPOSITE1,
1157 .vmux = 1,
1158 .gpio0 = 0x0000a75b,
1160 .type = CX88_VMUX_SVIDEO,
1161 .vmux = 2,
1162 .gpio0 = 0x0000a75b,
1164 .mpeg = CX88_MPEG_DVB,
1166 [CX88_BOARD_PCHDTV_HD5500] = {
1167 .name = "pcHDTV HD5500 HDTV",
1168 .tuner_type = TUNER_LG_TDVS_H06XF, /* TDVS-H064F */
1169 .radio_type = UNSET,
1170 .tuner_addr = ADDR_UNSET,
1171 .radio_addr = ADDR_UNSET,
1172 .tda9887_conf = TDA9887_PRESENT,
1173 .input = {{
1174 .type = CX88_VMUX_TELEVISION,
1175 .vmux = 0,
1176 .gpio0 = 0x87fd,
1178 .type = CX88_VMUX_COMPOSITE1,
1179 .vmux = 1,
1180 .gpio0 = 0x87f9,
1182 .type = CX88_VMUX_SVIDEO,
1183 .vmux = 2,
1184 .gpio0 = 0x87f9,
1186 .mpeg = CX88_MPEG_DVB,
1188 [CX88_BOARD_KWORLD_MCE200_DELUXE] = {
1189 .name = "Kworld MCE 200 Deluxe",
1190 .tuner_type = TUNER_TENA_9533_DI,
1191 .radio_type = UNSET,
1192 .tda9887_conf = TDA9887_PRESENT,
1193 .tuner_addr = ADDR_UNSET,
1194 .radio_addr = ADDR_UNSET,
1195 .input = {{
1196 .type = CX88_VMUX_TELEVISION,
1197 .vmux = 0,
1198 .gpio0 = 0x0000BDE6
1200 .mpeg = CX88_MPEG_BLACKBIRD,
1202 [CX88_BOARD_PIXELVIEW_PLAYTV_P7000] = {
1203 .name = "PixelView PlayTV P7000",
1204 .tuner_type = TUNER_PHILIPS_FM1216ME_MK3,
1205 .radio_type = UNSET,
1206 .tuner_addr = ADDR_UNSET,
1207 .radio_addr = ADDR_UNSET,
1208 .tda9887_conf = TDA9887_PRESENT | TDA9887_PORT1_ACTIVE |
1209 TDA9887_PORT2_ACTIVE,
1210 .input = {{
1211 .type = CX88_VMUX_TELEVISION,
1212 .vmux = 0,
1213 .gpio0 = 0x5da6,
1215 .mpeg = CX88_MPEG_BLACKBIRD,
1217 [CX88_BOARD_NPGTECH_REALTV_TOP10FM] = {
1218 .name = "NPG Tech Real TV FM Top 10",
1219 .tuner_type = TUNER_TNF_5335MF, /* Actually a TNF9535 */
1220 .radio_type = UNSET,
1221 .tuner_addr = ADDR_UNSET,
1222 .radio_addr = ADDR_UNSET,
1223 .input = {{
1224 .type = CX88_VMUX_TELEVISION,
1225 .vmux = 0,
1226 .gpio0 = 0x0788,
1228 .type = CX88_VMUX_COMPOSITE1,
1229 .vmux = 1,
1230 .gpio0 = 0x078b,
1232 .type = CX88_VMUX_SVIDEO,
1233 .vmux = 2,
1234 .gpio0 = 0x078b,
1236 .radio = {
1237 .type = CX88_RADIO,
1238 .gpio0 = 0x074a,
1241 [CX88_BOARD_WINFAST_DTV2000H] = {
1242 .name = "WinFast DTV2000 H",
1243 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1244 .radio_type = UNSET,
1245 .tuner_addr = ADDR_UNSET,
1246 .radio_addr = ADDR_UNSET,
1247 .tda9887_conf = TDA9887_PRESENT,
1248 .input = {{
1249 .type = CX88_VMUX_TELEVISION,
1250 .vmux = 0,
1251 .gpio0 = 0x00017304,
1252 .gpio1 = 0x00008203,
1253 .gpio2 = 0x00017304,
1254 .gpio3 = 0x02000000,
1255 }, {
1256 .type = CX88_VMUX_COMPOSITE1,
1257 .vmux = 1,
1258 .gpio0 = 0x0001d701,
1259 .gpio1 = 0x0000b207,
1260 .gpio2 = 0x0001d701,
1261 .gpio3 = 0x02000000,
1262 }, {
1263 .type = CX88_VMUX_COMPOSITE2,
1264 .vmux = 2,
1265 .gpio0 = 0x0001d503,
1266 .gpio1 = 0x0000b207,
1267 .gpio2 = 0x0001d503,
1268 .gpio3 = 0x02000000,
1269 }, {
1270 .type = CX88_VMUX_SVIDEO,
1271 .vmux = 3,
1272 .gpio0 = 0x0001d701,
1273 .gpio1 = 0x0000b207,
1274 .gpio2 = 0x0001d701,
1275 .gpio3 = 0x02000000,
1277 .radio = {
1278 .type = CX88_RADIO,
1279 .gpio0 = 0x00015702,
1280 .gpio1 = 0x0000f207,
1281 .gpio2 = 0x00015702,
1282 .gpio3 = 0x02000000,
1284 .mpeg = CX88_MPEG_DVB,
1286 [CX88_BOARD_WINFAST_DTV2000H_J] = {
1287 .name = "WinFast DTV2000 H rev. J",
1288 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1289 .radio_type = UNSET,
1290 .tuner_addr = ADDR_UNSET,
1291 .radio_addr = ADDR_UNSET,
1292 .tda9887_conf = TDA9887_PRESENT,
1293 .input = {{
1294 .type = CX88_VMUX_TELEVISION,
1295 .vmux = 0,
1296 .gpio0 = 0x00017300,
1297 .gpio1 = 0x00008207,
1298 .gpio2 = 0x00000000,
1299 .gpio3 = 0x02000000,
1301 .type = CX88_VMUX_TELEVISION,
1302 .vmux = 0,
1303 .gpio0 = 0x00018300,
1304 .gpio1 = 0x0000f207,
1305 .gpio2 = 0x00017304,
1306 .gpio3 = 0x02000000,
1308 .type = CX88_VMUX_COMPOSITE1,
1309 .vmux = 1,
1310 .gpio0 = 0x00018301,
1311 .gpio1 = 0x0000f207,
1312 .gpio2 = 0x00017304,
1313 .gpio3 = 0x02000000,
1315 .type = CX88_VMUX_SVIDEO,
1316 .vmux = 2,
1317 .gpio0 = 0x00018301,
1318 .gpio1 = 0x0000f207,
1319 .gpio2 = 0x00017304,
1320 .gpio3 = 0x02000000,
1322 .radio = {
1323 .type = CX88_RADIO,
1324 .gpio0 = 0x00015702,
1325 .gpio1 = 0x0000f207,
1326 .gpio2 = 0x00015702,
1327 .gpio3 = 0x02000000,
1329 .mpeg = CX88_MPEG_DVB,
1331 [CX88_BOARD_GENIATECH_DVBS] = {
1332 .name = "Geniatech DVB-S",
1333 .tuner_type = TUNER_ABSENT,
1334 .radio_type = UNSET,
1335 .tuner_addr = ADDR_UNSET,
1336 .radio_addr = ADDR_UNSET,
1337 .input = {{
1338 .type = CX88_VMUX_DVB,
1339 .vmux = 0,
1341 .type = CX88_VMUX_COMPOSITE1,
1342 .vmux = 1,
1344 .mpeg = CX88_MPEG_DVB,
1346 [CX88_BOARD_HAUPPAUGE_HVR3000] = {
1347 .name = "Hauppauge WinTV-HVR3000 TriMode Analog/DVB-S/DVB-T",
1348 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1349 .radio_type = UNSET,
1350 .tuner_addr = ADDR_UNSET,
1351 .radio_addr = ADDR_UNSET,
1352 .tda9887_conf = TDA9887_PRESENT,
1353 .audio_chip = V4L2_IDENT_WM8775,
1354 .input = {{
1355 .type = CX88_VMUX_TELEVISION,
1356 .vmux = 0,
1357 .gpio0 = 0x84bf,
1358 /* 1: TV Audio / FM Mono */
1359 .audioroute = 1,
1361 .type = CX88_VMUX_COMPOSITE1,
1362 .vmux = 1,
1363 .gpio0 = 0x84bf,
1364 /* 2: Line-In */
1365 .audioroute = 2,
1367 .type = CX88_VMUX_SVIDEO,
1368 .vmux = 2,
1369 .gpio0 = 0x84bf,
1370 /* 2: Line-In */
1371 .audioroute = 2,
1373 .radio = {
1374 .type = CX88_RADIO,
1375 .gpio0 = 0x84bf,
1376 /* 4: FM Stereo (untested) */
1377 .audioroute = 8,
1379 .mpeg = CX88_MPEG_DVB,
1380 .num_frontends = 2,
1382 [CX88_BOARD_NORWOOD_MICRO] = {
1383 .name = "Norwood Micro TV Tuner",
1384 .tuner_type = TUNER_TNF_5335MF,
1385 .radio_type = UNSET,
1386 .tuner_addr = ADDR_UNSET,
1387 .radio_addr = ADDR_UNSET,
1388 .input = {{
1389 .type = CX88_VMUX_TELEVISION,
1390 .vmux = 0,
1391 .gpio0 = 0x0709,
1393 .type = CX88_VMUX_COMPOSITE1,
1394 .vmux = 1,
1395 .gpio0 = 0x070b,
1397 .type = CX88_VMUX_SVIDEO,
1398 .vmux = 2,
1399 .gpio0 = 0x070b,
1402 [CX88_BOARD_TE_DTV_250_OEM_SWANN] = {
1403 .name = "Shenzhen Tungsten Ages Tech TE-DTV-250 / Swann OEM",
1404 .tuner_type = TUNER_LG_PAL_NEW_TAPC,
1405 .radio_type = UNSET,
1406 .tuner_addr = ADDR_UNSET,
1407 .radio_addr = ADDR_UNSET,
1408 .input = {{
1409 .type = CX88_VMUX_TELEVISION,
1410 .vmux = 0,
1411 .gpio0 = 0x003fffff,
1412 .gpio1 = 0x00e00000,
1413 .gpio2 = 0x003fffff,
1414 .gpio3 = 0x02000000,
1416 .type = CX88_VMUX_COMPOSITE1,
1417 .vmux = 1,
1418 .gpio0 = 0x003fffff,
1419 .gpio1 = 0x00e00000,
1420 .gpio2 = 0x003fffff,
1421 .gpio3 = 0x02000000,
1423 .type = CX88_VMUX_SVIDEO,
1424 .vmux = 2,
1425 .gpio0 = 0x003fffff,
1426 .gpio1 = 0x00e00000,
1427 .gpio2 = 0x003fffff,
1428 .gpio3 = 0x02000000,
1431 [CX88_BOARD_HAUPPAUGE_HVR1300] = {
1432 .name = "Hauppauge WinTV-HVR1300 DVB-T/Hybrid MPEG Encoder",
1433 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1434 .radio_type = UNSET,
1435 .tuner_addr = ADDR_UNSET,
1436 .radio_addr = ADDR_UNSET,
1437 .tda9887_conf = TDA9887_PRESENT,
1438 .audio_chip = V4L2_IDENT_WM8775,
1440 * gpio0 as reported by Mike Crash <mike AT mikecrash.com>
1442 .input = {{
1443 .type = CX88_VMUX_TELEVISION,
1444 .vmux = 0,
1445 .gpio0 = 0xef88,
1446 /* 1: TV Audio / FM Mono */
1447 .audioroute = 1,
1449 .type = CX88_VMUX_COMPOSITE1,
1450 .vmux = 1,
1451 .gpio0 = 0xef88,
1452 /* 2: Line-In */
1453 .audioroute = 2,
1455 .type = CX88_VMUX_SVIDEO,
1456 .vmux = 2,
1457 .gpio0 = 0xef88,
1458 /* 2: Line-In */
1459 .audioroute = 2,
1461 .mpeg = CX88_MPEG_DVB | CX88_MPEG_BLACKBIRD,
1462 .radio = {
1463 .type = CX88_RADIO,
1464 .gpio0 = 0xef88,
1465 /* 4: FM Stereo (untested) */
1466 .audioroute = 8,
1469 [CX88_BOARD_SAMSUNG_SMT_7020] = {
1470 .name = "Samsung SMT 7020 DVB-S",
1471 .tuner_type = TUNER_ABSENT,
1472 .radio_type = UNSET,
1473 .tuner_addr = ADDR_UNSET,
1474 .radio_addr = ADDR_UNSET,
1475 .input = { {
1476 .type = CX88_VMUX_DVB,
1477 .vmux = 0,
1478 } },
1479 .mpeg = CX88_MPEG_DVB,
1481 [CX88_BOARD_ADSTECH_PTV_390] = {
1482 .name = "ADS Tech Instant Video PCI",
1483 .tuner_type = TUNER_ABSENT,
1484 .radio_type = UNSET,
1485 .tuner_addr = ADDR_UNSET,
1486 .radio_addr = ADDR_UNSET,
1487 .input = {{
1488 .type = CX88_VMUX_DEBUG,
1489 .vmux = 3,
1490 .gpio0 = 0x04ff,
1492 .type = CX88_VMUX_COMPOSITE1,
1493 .vmux = 1,
1494 .gpio0 = 0x07fa,
1496 .type = CX88_VMUX_SVIDEO,
1497 .vmux = 2,
1498 .gpio0 = 0x07fa,
1501 [CX88_BOARD_PINNACLE_PCTV_HD_800i] = {
1502 .name = "Pinnacle PCTV HD 800i",
1503 .tuner_type = TUNER_XC5000,
1504 .radio_type = UNSET,
1505 .tuner_addr = ADDR_UNSET,
1506 .radio_addr = ADDR_UNSET,
1507 .input = {{
1508 .type = CX88_VMUX_TELEVISION,
1509 .vmux = 0,
1510 .gpio0 = 0x04fb,
1511 .gpio1 = 0x10ff,
1513 .type = CX88_VMUX_COMPOSITE1,
1514 .vmux = 1,
1515 .gpio0 = 0x04fb,
1516 .gpio1 = 0x10ef,
1517 .audioroute = 1,
1519 .type = CX88_VMUX_SVIDEO,
1520 .vmux = 2,
1521 .gpio0 = 0x04fb,
1522 .gpio1 = 0x10ef,
1523 .audioroute = 1,
1525 .mpeg = CX88_MPEG_DVB,
1527 [CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO] = {
1528 .name = "DViCO FusionHDTV 5 PCI nano",
1529 /* xc3008 tuner, digital only for now */
1530 .tuner_type = TUNER_ABSENT,
1531 .radio_type = UNSET,
1532 .tuner_addr = ADDR_UNSET,
1533 .radio_addr = ADDR_UNSET,
1534 .input = {{
1535 .type = CX88_VMUX_TELEVISION,
1536 .vmux = 0,
1537 .gpio0 = 0x000027df, /* Unconfirmed */
1538 }, {
1539 .type = CX88_VMUX_COMPOSITE1,
1540 .vmux = 1,
1541 .gpio0 = 0x000027df, /* Unconfirmed */
1542 .audioroute = 1,
1543 }, {
1544 .type = CX88_VMUX_SVIDEO,
1545 .vmux = 2,
1546 .gpio0 = 0x000027df, /* Unconfirmed */
1547 .audioroute = 1,
1548 } },
1549 .mpeg = CX88_MPEG_DVB,
1551 [CX88_BOARD_PINNACLE_HYBRID_PCTV] = {
1552 .name = "Pinnacle Hybrid PCTV",
1553 .tuner_type = TUNER_XC2028,
1554 .tuner_addr = 0x61,
1555 .radio_type = TUNER_XC2028,
1556 .radio_addr = 0x61,
1557 .input = { {
1558 .type = CX88_VMUX_TELEVISION,
1559 .vmux = 0,
1560 .gpio0 = 0x004ff,
1561 .gpio1 = 0x010ff,
1562 .gpio2 = 0x00001,
1563 }, {
1564 .type = CX88_VMUX_COMPOSITE1,
1565 .vmux = 1,
1566 .gpio0 = 0x004fb,
1567 .gpio1 = 0x010ef,
1568 .audioroute = 1,
1569 }, {
1570 .type = CX88_VMUX_SVIDEO,
1571 .vmux = 2,
1572 .gpio0 = 0x004fb,
1573 .gpio1 = 0x010ef,
1574 .audioroute = 1,
1575 } },
1576 .radio = {
1577 .type = CX88_RADIO,
1578 .gpio0 = 0x004ff,
1579 .gpio1 = 0x010ff,
1580 .gpio2 = 0x0ff,
1582 .mpeg = CX88_MPEG_DVB,
1584 /* Terry Wu <terrywu2009@gmail.com> */
1585 /* TV Audio : set GPIO 2, 18, 19 value to 0, 1, 0 */
1586 /* FM Audio : set GPIO 2, 18, 19 value to 0, 0, 0 */
1587 /* Line-in Audio : set GPIO 2, 18, 19 value to 0, 1, 1 */
1588 /* Mute Audio : set GPIO 2 value to 1 */
1589 [CX88_BOARD_WINFAST_TV2000_XP_GLOBAL] = {
1590 .name = "Leadtek TV2000 XP Global",
1591 .tuner_type = TUNER_XC2028,
1592 .tuner_addr = 0x61,
1593 .radio_type = TUNER_XC2028,
1594 .radio_addr = 0x61,
1595 .input = { {
1596 .type = CX88_VMUX_TELEVISION,
1597 .vmux = 0,
1598 .gpio0 = 0x0400, /* pin 2 = 0 */
1599 .gpio1 = 0x0000,
1600 .gpio2 = 0x0C04, /* pin 18 = 1, pin 19 = 0 */
1601 .gpio3 = 0x0000,
1602 }, {
1603 .type = CX88_VMUX_COMPOSITE1,
1604 .vmux = 1,
1605 .gpio0 = 0x0400, /* pin 2 = 0 */
1606 .gpio1 = 0x0000,
1607 .gpio2 = 0x0C0C, /* pin 18 = 1, pin 19 = 1 */
1608 .gpio3 = 0x0000,
1609 }, {
1610 .type = CX88_VMUX_SVIDEO,
1611 .vmux = 2,
1612 .gpio0 = 0x0400, /* pin 2 = 0 */
1613 .gpio1 = 0x0000,
1614 .gpio2 = 0x0C0C, /* pin 18 = 1, pin 19 = 1 */
1615 .gpio3 = 0x0000,
1616 } },
1617 .radio = {
1618 .type = CX88_RADIO,
1619 .gpio0 = 0x0400, /* pin 2 = 0 */
1620 .gpio1 = 0x0000,
1621 .gpio2 = 0x0C00, /* pin 18 = 0, pin 19 = 0 */
1622 .gpio3 = 0x0000,
1625 [CX88_BOARD_POWERCOLOR_REAL_ANGEL] = {
1626 .name = "PowerColor RA330", /* Long names may confuse LIRC. */
1627 .tuner_type = TUNER_XC2028,
1628 .tuner_addr = 0x61,
1629 .input = { {
1630 .type = CX88_VMUX_DEBUG,
1631 .vmux = 3, /* Due to the way the cx88 driver is written, */
1632 .gpio0 = 0x00ff, /* there is no way to deactivate audio pass- */
1633 .gpio1 = 0xf39d, /* through without this entry. Furthermore, if */
1634 .gpio3 = 0x0000, /* the TV mux entry is first, you get audio */
1635 }, { /* from the tuner on boot for a little while. */
1636 .type = CX88_VMUX_TELEVISION,
1637 .vmux = 0,
1638 .gpio0 = 0x00ff,
1639 .gpio1 = 0xf35d,
1640 .gpio3 = 0x0000,
1641 }, {
1642 .type = CX88_VMUX_COMPOSITE1,
1643 .vmux = 1,
1644 .gpio0 = 0x00ff,
1645 .gpio1 = 0xf37d,
1646 .gpio3 = 0x0000,
1647 }, {
1648 .type = CX88_VMUX_SVIDEO,
1649 .vmux = 2,
1650 .gpio0 = 0x000ff,
1651 .gpio1 = 0x0f37d,
1652 .gpio3 = 0x00000,
1653 } },
1654 .radio = {
1655 .type = CX88_RADIO,
1656 .gpio0 = 0x000ff,
1657 .gpio1 = 0x0f35d,
1658 .gpio3 = 0x00000,
1661 [CX88_BOARD_GENIATECH_X8000_MT] = {
1662 /* Also PowerColor Real Angel 330 and Geniatech X800 OEM */
1663 .name = "Geniatech X8000-MT DVBT",
1664 .tuner_type = TUNER_XC2028,
1665 .tuner_addr = 0x61,
1666 .input = { {
1667 .type = CX88_VMUX_TELEVISION,
1668 .vmux = 0,
1669 .gpio0 = 0x00000000,
1670 .gpio1 = 0x00e3e341,
1671 .gpio2 = 0x00000000,
1672 .gpio3 = 0x00000000,
1673 }, {
1674 .type = CX88_VMUX_COMPOSITE1,
1675 .vmux = 1,
1676 .gpio0 = 0x00000000,
1677 .gpio1 = 0x00e3e361,
1678 .gpio2 = 0x00000000,
1679 .gpio3 = 0x00000000,
1680 }, {
1681 .type = CX88_VMUX_SVIDEO,
1682 .vmux = 2,
1683 .gpio0 = 0x00000000,
1684 .gpio1 = 0x00e3e361,
1685 .gpio2 = 0x00000000,
1686 .gpio3 = 0x00000000,
1687 } },
1688 .radio = {
1689 .type = CX88_RADIO,
1690 .gpio0 = 0x00000000,
1691 .gpio1 = 0x00e3e341,
1692 .gpio2 = 0x00000000,
1693 .gpio3 = 0x00000000,
1695 .mpeg = CX88_MPEG_DVB,
1697 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO] = {
1698 .name = "DViCO FusionHDTV DVB-T PRO",
1699 .tuner_type = TUNER_XC2028,
1700 .tuner_addr = 0x61,
1701 .radio_type = UNSET,
1702 .radio_addr = ADDR_UNSET,
1703 .input = { {
1704 .type = CX88_VMUX_COMPOSITE1,
1705 .vmux = 1,
1706 .gpio0 = 0x000067df,
1707 }, {
1708 .type = CX88_VMUX_SVIDEO,
1709 .vmux = 2,
1710 .gpio0 = 0x000067df,
1711 } },
1712 .mpeg = CX88_MPEG_DVB,
1714 [CX88_BOARD_DVICO_FUSIONHDTV_7_GOLD] = {
1715 .name = "DViCO FusionHDTV 7 Gold",
1716 .tuner_type = TUNER_XC5000,
1717 .radio_type = UNSET,
1718 .tuner_addr = ADDR_UNSET,
1719 .radio_addr = ADDR_UNSET,
1720 .input = {{
1721 .type = CX88_VMUX_TELEVISION,
1722 .vmux = 0,
1723 .gpio0 = 0x10df,
1725 .type = CX88_VMUX_COMPOSITE1,
1726 .vmux = 1,
1727 .gpio0 = 0x16d9,
1729 .type = CX88_VMUX_SVIDEO,
1730 .vmux = 2,
1731 .gpio0 = 0x16d9,
1733 .mpeg = CX88_MPEG_DVB,
1735 [CX88_BOARD_PROLINK_PV_8000GT] = {
1736 .name = "Prolink Pixelview MPEG 8000GT",
1737 .tuner_type = TUNER_XC2028,
1738 .tuner_addr = 0x61,
1739 .input = { {
1740 .type = CX88_VMUX_TELEVISION,
1741 .vmux = 0,
1742 .gpio0 = 0x0ff,
1743 .gpio2 = 0x0cfb,
1744 }, {
1745 .type = CX88_VMUX_COMPOSITE1,
1746 .vmux = 1,
1747 .gpio2 = 0x0cfb,
1748 }, {
1749 .type = CX88_VMUX_SVIDEO,
1750 .vmux = 2,
1751 .gpio2 = 0x0cfb,
1752 } },
1753 .radio = {
1754 .type = CX88_RADIO,
1755 .gpio2 = 0x0cfb,
1758 [CX88_BOARD_PROLINK_PV_GLOBAL_XTREME] = {
1759 .name = "Prolink Pixelview Global Extreme",
1760 .tuner_type = TUNER_XC2028,
1761 .tuner_addr = 0x61,
1762 .input = { {
1763 .type = CX88_VMUX_TELEVISION,
1764 .vmux = 0,
1765 .gpio0 = 0x04fb,
1766 .gpio1 = 0x04080,
1767 .gpio2 = 0x0cf7,
1768 }, {
1769 .type = CX88_VMUX_COMPOSITE1,
1770 .vmux = 1,
1771 .gpio0 = 0x04fb,
1772 .gpio1 = 0x04080,
1773 .gpio2 = 0x0cfb,
1774 }, {
1775 .type = CX88_VMUX_SVIDEO,
1776 .vmux = 2,
1777 .gpio0 = 0x04fb,
1778 .gpio1 = 0x04080,
1779 .gpio2 = 0x0cfb,
1780 } },
1781 .radio = {
1782 .type = CX88_RADIO,
1783 .gpio0 = 0x04ff,
1784 .gpio1 = 0x04080,
1785 .gpio2 = 0x0cf7,
1788 /* Both radio, analog and ATSC work with this board.
1789 However, for analog to work, s5h1409 gate should be open,
1790 otherwise, tuner-xc3028 won't be detected.
1791 A proper fix require using the newer i2c methods to add
1792 tuner-xc3028 without doing an i2c probe.
1794 [CX88_BOARD_KWORLD_ATSC_120] = {
1795 .name = "Kworld PlusTV HD PCI 120 (ATSC 120)",
1796 .tuner_type = TUNER_XC2028,
1797 .radio_type = UNSET,
1798 .tuner_addr = ADDR_UNSET,
1799 .radio_addr = ADDR_UNSET,
1800 .input = { {
1801 .type = CX88_VMUX_TELEVISION,
1802 .vmux = 0,
1803 .gpio0 = 0x000000ff,
1804 .gpio1 = 0x0000f35d,
1805 .gpio2 = 0x00000000,
1806 }, {
1807 .type = CX88_VMUX_COMPOSITE1,
1808 .vmux = 1,
1809 .gpio0 = 0x000000ff,
1810 .gpio1 = 0x0000f37e,
1811 .gpio2 = 0x00000000,
1812 }, {
1813 .type = CX88_VMUX_SVIDEO,
1814 .vmux = 2,
1815 .gpio0 = 0x000000ff,
1816 .gpio1 = 0x0000f37e,
1817 .gpio2 = 0x00000000,
1818 } },
1819 .radio = {
1820 .type = CX88_RADIO,
1821 .gpio0 = 0x000000ff,
1822 .gpio1 = 0x0000f35d,
1823 .gpio2 = 0x00000000,
1825 .mpeg = CX88_MPEG_DVB,
1827 [CX88_BOARD_HAUPPAUGE_HVR4000] = {
1828 .name = "Hauppauge WinTV-HVR4000 DVB-S/S2/T/Hybrid",
1829 .tuner_type = TUNER_PHILIPS_FMD1216ME_MK3,
1830 .radio_type = UNSET,
1831 .tuner_addr = ADDR_UNSET,
1832 .radio_addr = ADDR_UNSET,
1833 .tda9887_conf = TDA9887_PRESENT,
1834 .audio_chip = V4L2_IDENT_WM8775,
1836 * GPIO0 (WINTV2000)
1838 * Analogue SAT DVB-T
1839 * Antenna 0xc4bf 0xc4bb
1840 * Composite 0xc4bf 0xc4bb
1841 * S-Video 0xc4bf 0xc4bb
1842 * Composite1 0xc4ff 0xc4fb
1843 * S-Video1 0xc4ff 0xc4fb
1845 * BIT VALUE FUNCTION GP{x}_IO
1846 * 0 1 I:?
1847 * 1 1 I:?
1848 * 2 1 O:MPEG PORT 0=DVB-T 1=DVB-S
1849 * 3 1 I:?
1850 * 4 1 I:?
1851 * 5 1 I:?
1852 * 6 0 O:INPUT SELECTOR 0=INTERNAL 1=EXPANSION
1853 * 7 1 O:DVB-T DEMOD RESET LOW
1855 * BIT VALUE FUNCTION GP{x}_OE
1856 * 8 0 I
1857 * 9 0 I
1858 * a 1 O
1859 * b 0 I
1860 * c 0 I
1861 * d 0 I
1862 * e 1 O
1863 * f 1 O
1865 * WM8775 ADC
1867 * 1: TV Audio / FM Mono
1868 * 2: Line-In
1869 * 3: Line-In Expansion
1870 * 4: FM Stereo
1872 .input = {{
1873 .type = CX88_VMUX_TELEVISION,
1874 .vmux = 0,
1875 .gpio0 = 0xc4bf,
1876 /* 1: TV Audio / FM Mono */
1877 .audioroute = 1,
1878 }, {
1879 .type = CX88_VMUX_COMPOSITE1,
1880 .vmux = 1,
1881 .gpio0 = 0xc4bf,
1882 /* 2: Line-In */
1883 .audioroute = 2,
1884 }, {
1885 .type = CX88_VMUX_SVIDEO,
1886 .vmux = 2,
1887 .gpio0 = 0xc4bf,
1888 /* 2: Line-In */
1889 .audioroute = 2,
1890 } },
1891 .radio = {
1892 .type = CX88_RADIO,
1893 .gpio0 = 0xc4bf,
1894 /* 4: FM Stereo */
1895 .audioroute = 8,
1897 .mpeg = CX88_MPEG_DVB,
1898 .num_frontends = 2,
1900 [CX88_BOARD_HAUPPAUGE_HVR4000LITE] = {
1901 .name = "Hauppauge WinTV-HVR4000(Lite) DVB-S/S2",
1902 .tuner_type = UNSET,
1903 .radio_type = UNSET,
1904 .tuner_addr = ADDR_UNSET,
1905 .radio_addr = ADDR_UNSET,
1906 .input = {{
1907 .type = CX88_VMUX_DVB,
1908 .vmux = 0,
1909 } },
1910 .mpeg = CX88_MPEG_DVB,
1912 [CX88_BOARD_TEVII_S420] = {
1913 .name = "TeVii S420 DVB-S",
1914 .tuner_type = UNSET,
1915 .radio_type = UNSET,
1916 .tuner_addr = ADDR_UNSET,
1917 .radio_addr = ADDR_UNSET,
1918 .input = {{
1919 .type = CX88_VMUX_DVB,
1920 .vmux = 0,
1921 } },
1922 .mpeg = CX88_MPEG_DVB,
1924 [CX88_BOARD_TEVII_S460] = {
1925 .name = "TeVii S460 DVB-S/S2",
1926 .tuner_type = UNSET,
1927 .radio_type = UNSET,
1928 .tuner_addr = ADDR_UNSET,
1929 .radio_addr = ADDR_UNSET,
1930 .input = {{
1931 .type = CX88_VMUX_DVB,
1932 .vmux = 0,
1933 } },
1934 .mpeg = CX88_MPEG_DVB,
1936 [CX88_BOARD_OMICOM_SS4_PCI] = {
1937 .name = "Omicom SS4 DVB-S/S2 PCI",
1938 .tuner_type = UNSET,
1939 .radio_type = UNSET,
1940 .tuner_addr = ADDR_UNSET,
1941 .radio_addr = ADDR_UNSET,
1942 .input = {{
1943 .type = CX88_VMUX_DVB,
1944 .vmux = 0,
1945 } },
1946 .mpeg = CX88_MPEG_DVB,
1948 [CX88_BOARD_TBS_8910] = {
1949 .name = "TBS 8910 DVB-S",
1950 .tuner_type = UNSET,
1951 .radio_type = UNSET,
1952 .tuner_addr = ADDR_UNSET,
1953 .radio_addr = ADDR_UNSET,
1954 .input = {{
1955 .type = CX88_VMUX_DVB,
1956 .vmux = 0,
1957 } },
1958 .mpeg = CX88_MPEG_DVB,
1960 [CX88_BOARD_TBS_8920] = {
1961 .name = "TBS 8920 DVB-S/S2",
1962 .tuner_type = TUNER_ABSENT,
1963 .radio_type = UNSET,
1964 .tuner_addr = ADDR_UNSET,
1965 .radio_addr = ADDR_UNSET,
1966 .input = {{
1967 .type = CX88_VMUX_DVB,
1968 .vmux = 0,
1969 .gpio0 = 0x8080,
1970 } },
1971 .mpeg = CX88_MPEG_DVB,
1973 [CX88_BOARD_PROF_6200] = {
1974 .name = "Prof 6200 DVB-S",
1975 .tuner_type = UNSET,
1976 .radio_type = UNSET,
1977 .tuner_addr = ADDR_UNSET,
1978 .radio_addr = ADDR_UNSET,
1979 .input = {{
1980 .type = CX88_VMUX_DVB,
1981 .vmux = 0,
1982 } },
1983 .mpeg = CX88_MPEG_DVB,
1985 [CX88_BOARD_PROF_7300] = {
1986 .name = "PROF 7300 DVB-S/S2",
1987 .tuner_type = UNSET,
1988 .radio_type = UNSET,
1989 .tuner_addr = ADDR_UNSET,
1990 .radio_addr = ADDR_UNSET,
1991 .input = {{
1992 .type = CX88_VMUX_DVB,
1993 .vmux = 0,
1994 } },
1995 .mpeg = CX88_MPEG_DVB,
1997 [CX88_BOARD_SATTRADE_ST4200] = {
1998 .name = "SATTRADE ST4200 DVB-S/S2",
1999 .tuner_type = UNSET,
2000 .radio_type = UNSET,
2001 .tuner_addr = ADDR_UNSET,
2002 .radio_addr = ADDR_UNSET,
2003 .input = {{
2004 .type = CX88_VMUX_DVB,
2005 .vmux = 0,
2006 } },
2007 .mpeg = CX88_MPEG_DVB,
2009 [CX88_BOARD_TERRATEC_CINERGY_HT_PCI_MKII] = {
2010 .name = "Terratec Cinergy HT PCI MKII",
2011 .tuner_type = TUNER_XC2028,
2012 .tuner_addr = 0x61,
2013 .radio_type = TUNER_XC2028,
2014 .radio_addr = 0x61,
2015 .input = { {
2016 .type = CX88_VMUX_TELEVISION,
2017 .vmux = 0,
2018 .gpio0 = 0x004ff,
2019 .gpio1 = 0x010ff,
2020 .gpio2 = 0x00001,
2021 }, {
2022 .type = CX88_VMUX_COMPOSITE1,
2023 .vmux = 1,
2024 .gpio0 = 0x004fb,
2025 .gpio1 = 0x010ef,
2026 .audioroute = 1,
2027 }, {
2028 .type = CX88_VMUX_SVIDEO,
2029 .vmux = 2,
2030 .gpio0 = 0x004fb,
2031 .gpio1 = 0x010ef,
2032 .audioroute = 1,
2033 } },
2034 .radio = {
2035 .type = CX88_RADIO,
2036 .gpio0 = 0x004ff,
2037 .gpio1 = 0x010ff,
2038 .gpio2 = 0x0ff,
2040 .mpeg = CX88_MPEG_DVB,
2042 [CX88_BOARD_HAUPPAUGE_IRONLY] = {
2043 .name = "Hauppauge WinTV-IR Only",
2044 .tuner_type = UNSET,
2045 .radio_type = UNSET,
2046 .tuner_addr = ADDR_UNSET,
2047 .radio_addr = ADDR_UNSET,
2049 [CX88_BOARD_WINFAST_DTV1800H] = {
2050 .name = "Leadtek WinFast DTV1800 Hybrid",
2051 .tuner_type = TUNER_XC2028,
2052 .radio_type = TUNER_XC2028,
2053 .tuner_addr = 0x61,
2054 .radio_addr = 0x61,
2056 * GPIO setting
2058 * 2: mute (0=off,1=on)
2059 * 12: tuner reset pin
2060 * 13: audio source (0=tuner audio,1=line in)
2061 * 14: FM (0=on,1=off ???)
2063 .input = {{
2064 .type = CX88_VMUX_TELEVISION,
2065 .vmux = 0,
2066 .gpio0 = 0x0400, /* pin 2 = 0 */
2067 .gpio1 = 0x6040, /* pin 13 = 0, pin 14 = 1 */
2068 .gpio2 = 0x0000,
2069 }, {
2070 .type = CX88_VMUX_COMPOSITE1,
2071 .vmux = 1,
2072 .gpio0 = 0x0400, /* pin 2 = 0 */
2073 .gpio1 = 0x6060, /* pin 13 = 1, pin 14 = 1 */
2074 .gpio2 = 0x0000,
2075 }, {
2076 .type = CX88_VMUX_SVIDEO,
2077 .vmux = 2,
2078 .gpio0 = 0x0400, /* pin 2 = 0 */
2079 .gpio1 = 0x6060, /* pin 13 = 1, pin 14 = 1 */
2080 .gpio2 = 0x0000,
2081 } },
2082 .radio = {
2083 .type = CX88_RADIO,
2084 .gpio0 = 0x0400, /* pin 2 = 0 */
2085 .gpio1 = 0x6000, /* pin 13 = 0, pin 14 = 0 */
2086 .gpio2 = 0x0000,
2088 .mpeg = CX88_MPEG_DVB,
2090 [CX88_BOARD_PROF_7301] = {
2091 .name = "Prof 7301 DVB-S/S2",
2092 .tuner_type = UNSET,
2093 .radio_type = UNSET,
2094 .tuner_addr = ADDR_UNSET,
2095 .radio_addr = ADDR_UNSET,
2096 .input = { {
2097 .type = CX88_VMUX_DVB,
2098 .vmux = 0,
2099 } },
2100 .mpeg = CX88_MPEG_DVB,
2104 /* ------------------------------------------------------------------ */
2105 /* PCI subsystem IDs */
2107 static const struct cx88_subid cx88_subids[] = {
2109 .subvendor = 0x0070,
2110 .subdevice = 0x3400,
2111 .card = CX88_BOARD_HAUPPAUGE,
2113 .subvendor = 0x0070,
2114 .subdevice = 0x3401,
2115 .card = CX88_BOARD_HAUPPAUGE,
2117 .subvendor = 0x14c7,
2118 .subdevice = 0x0106,
2119 .card = CX88_BOARD_GDI,
2121 .subvendor = 0x14c7,
2122 .subdevice = 0x0107, /* with mpeg encoder */
2123 .card = CX88_BOARD_GDI,
2125 .subvendor = PCI_VENDOR_ID_ATI,
2126 .subdevice = 0x00f8,
2127 .card = CX88_BOARD_ATI_WONDER_PRO,
2128 }, {
2129 .subvendor = PCI_VENDOR_ID_ATI,
2130 .subdevice = 0x00f9,
2131 .card = CX88_BOARD_ATI_WONDER_PRO,
2132 }, {
2133 .subvendor = 0x107d,
2134 .subdevice = 0x6611,
2135 .card = CX88_BOARD_WINFAST2000XP_EXPERT,
2137 .subvendor = 0x107d,
2138 .subdevice = 0x6613, /* NTSC */
2139 .card = CX88_BOARD_WINFAST2000XP_EXPERT,
2141 .subvendor = 0x107d,
2142 .subdevice = 0x6620,
2143 .card = CX88_BOARD_WINFAST_DV2000,
2145 .subvendor = 0x107d,
2146 .subdevice = 0x663b,
2147 .card = CX88_BOARD_LEADTEK_PVR2000,
2149 .subvendor = 0x107d,
2150 .subdevice = 0x663c,
2151 .card = CX88_BOARD_LEADTEK_PVR2000,
2153 .subvendor = 0x1461,
2154 .subdevice = 0x000b,
2155 .card = CX88_BOARD_AVERTV_STUDIO_303,
2157 .subvendor = 0x1462,
2158 .subdevice = 0x8606,
2159 .card = CX88_BOARD_MSI_TVANYWHERE_MASTER,
2161 .subvendor = 0x10fc,
2162 .subdevice = 0xd003,
2163 .card = CX88_BOARD_IODATA_GVVCP3PCI,
2165 .subvendor = 0x1043,
2166 .subdevice = 0x4823, /* with mpeg encoder */
2167 .card = CX88_BOARD_ASUS_PVR_416,
2169 .subvendor = 0x17de,
2170 .subdevice = 0x08a6,
2171 .card = CX88_BOARD_KWORLD_DVB_T,
2173 .subvendor = 0x18ac,
2174 .subdevice = 0xd810,
2175 .card = CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q,
2177 .subvendor = 0x18ac,
2178 .subdevice = 0xd820,
2179 .card = CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_T,
2181 .subvendor = 0x18ac,
2182 .subdevice = 0xdb00,
2183 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1,
2185 .subvendor = 0x0070,
2186 .subdevice = 0x9002,
2187 .card = CX88_BOARD_HAUPPAUGE_DVB_T1,
2189 .subvendor = 0x14f1,
2190 .subdevice = 0x0187,
2191 .card = CX88_BOARD_CONEXANT_DVB_T1,
2193 .subvendor = 0x1540,
2194 .subdevice = 0x2580,
2195 .card = CX88_BOARD_PROVIDEO_PV259,
2197 .subvendor = 0x18ac,
2198 .subdevice = 0xdb10,
2199 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS,
2201 .subvendor = 0x1554,
2202 .subdevice = 0x4811,
2203 .card = CX88_BOARD_PIXELVIEW,
2205 .subvendor = 0x7063,
2206 .subdevice = 0x3000, /* HD-3000 card */
2207 .card = CX88_BOARD_PCHDTV_HD3000,
2209 .subvendor = 0x17de,
2210 .subdevice = 0xa8a6,
2211 .card = CX88_BOARD_DNTV_LIVE_DVB_T,
2213 .subvendor = 0x0070,
2214 .subdevice = 0x2801,
2215 .card = CX88_BOARD_HAUPPAUGE_ROSLYN,
2217 .subvendor = 0x14f1,
2218 .subdevice = 0x0342,
2219 .card = CX88_BOARD_DIGITALLOGIC_MEC,
2221 .subvendor = 0x10fc,
2222 .subdevice = 0xd035,
2223 .card = CX88_BOARD_IODATA_GVBCTV7E,
2225 .subvendor = 0x1421,
2226 .subdevice = 0x0334,
2227 .card = CX88_BOARD_ADSTECH_DVB_T_PCI,
2229 .subvendor = 0x153b,
2230 .subdevice = 0x1166,
2231 .card = CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1,
2233 .subvendor = 0x18ac,
2234 .subdevice = 0xd500,
2235 .card = CX88_BOARD_DVICO_FUSIONHDTV_5_GOLD,
2237 .subvendor = 0x1461,
2238 .subdevice = 0x8011,
2239 .card = CX88_BOARD_AVERMEDIA_ULTRATV_MC_550,
2241 .subvendor = PCI_VENDOR_ID_ATI,
2242 .subdevice = 0xa101,
2243 .card = CX88_BOARD_ATI_HDTVWONDER,
2245 .subvendor = 0x107d,
2246 .subdevice = 0x665f,
2247 .card = CX88_BOARD_WINFAST_DTV1000,
2249 .subvendor = 0x1461,
2250 .subdevice = 0x000a,
2251 .card = CX88_BOARD_AVERTV_303,
2253 .subvendor = 0x0070,
2254 .subdevice = 0x9200,
2255 .card = CX88_BOARD_HAUPPAUGE_NOVASE2_S1,
2257 .subvendor = 0x0070,
2258 .subdevice = 0x9201,
2259 .card = CX88_BOARD_HAUPPAUGE_NOVASPLUS_S1,
2261 .subvendor = 0x0070,
2262 .subdevice = 0x9202,
2263 .card = CX88_BOARD_HAUPPAUGE_NOVASPLUS_S1,
2265 .subvendor = 0x17de,
2266 .subdevice = 0x08b2,
2267 .card = CX88_BOARD_KWORLD_DVBS_100,
2269 .subvendor = 0x0070,
2270 .subdevice = 0x9400,
2271 .card = CX88_BOARD_HAUPPAUGE_HVR1100,
2273 .subvendor = 0x0070,
2274 .subdevice = 0x9402,
2275 .card = CX88_BOARD_HAUPPAUGE_HVR1100,
2277 .subvendor = 0x0070,
2278 .subdevice = 0x9800,
2279 .card = CX88_BOARD_HAUPPAUGE_HVR1100LP,
2281 .subvendor = 0x0070,
2282 .subdevice = 0x9802,
2283 .card = CX88_BOARD_HAUPPAUGE_HVR1100LP,
2285 .subvendor = 0x0070,
2286 .subdevice = 0x9001,
2287 .card = CX88_BOARD_HAUPPAUGE_DVB_T1,
2289 .subvendor = 0x1822,
2290 .subdevice = 0x0025,
2291 .card = CX88_BOARD_DNTV_LIVE_DVB_T_PRO,
2293 .subvendor = 0x17de,
2294 .subdevice = 0x08a1,
2295 .card = CX88_BOARD_KWORLD_DVB_T_CX22702,
2297 .subvendor = 0x18ac,
2298 .subdevice = 0xdb50,
2299 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL,
2301 .subvendor = 0x18ac,
2302 .subdevice = 0xdb54,
2303 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL,
2304 /* Re-branded DViCO: DigitalNow DVB-T Dual */
2306 .subvendor = 0x18ac,
2307 .subdevice = 0xdb11,
2308 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS,
2309 /* Re-branded DViCO: UltraView DVB-T Plus */
2310 }, {
2311 .subvendor = 0x18ac,
2312 .subdevice = 0xdb30,
2313 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO,
2314 }, {
2315 .subvendor = 0x17de,
2316 .subdevice = 0x0840,
2317 .card = CX88_BOARD_KWORLD_HARDWARE_MPEG_TV_XPERT,
2319 .subvendor = 0x1421,
2320 .subdevice = 0x0305,
2321 .card = CX88_BOARD_KWORLD_HARDWARE_MPEG_TV_XPERT,
2323 .subvendor = 0x18ac,
2324 .subdevice = 0xdb40,
2325 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_HYBRID,
2327 .subvendor = 0x18ac,
2328 .subdevice = 0xdb44,
2329 .card = CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_HYBRID,
2331 .subvendor = 0x7063,
2332 .subdevice = 0x5500,
2333 .card = CX88_BOARD_PCHDTV_HD5500,
2335 .subvendor = 0x17de,
2336 .subdevice = 0x0841,
2337 .card = CX88_BOARD_KWORLD_MCE200_DELUXE,
2339 .subvendor = 0x1822,
2340 .subdevice = 0x0019,
2341 .card = CX88_BOARD_DNTV_LIVE_DVB_T_PRO,
2343 .subvendor = 0x1554,
2344 .subdevice = 0x4813,
2345 .card = CX88_BOARD_PIXELVIEW_PLAYTV_P7000,
2347 .subvendor = 0x14f1,
2348 .subdevice = 0x0842,
2349 .card = CX88_BOARD_NPGTECH_REALTV_TOP10FM,
2351 .subvendor = 0x107d,
2352 .subdevice = 0x665e,
2353 .card = CX88_BOARD_WINFAST_DTV2000H,
2355 .subvendor = 0x107d,
2356 .subdevice = 0x6f2b,
2357 .card = CX88_BOARD_WINFAST_DTV2000H_J,
2359 .subvendor = 0x18ac,
2360 .subdevice = 0xd800, /* FusionHDTV 3 Gold (original revision) */
2361 .card = CX88_BOARD_DVICO_FUSIONHDTV_3_GOLD_Q,
2363 .subvendor = 0x14f1,
2364 .subdevice = 0x0084,
2365 .card = CX88_BOARD_GENIATECH_DVBS,
2367 .subvendor = 0x0070,
2368 .subdevice = 0x1404,
2369 .card = CX88_BOARD_HAUPPAUGE_HVR3000,
2370 }, {
2371 .subvendor = 0x18ac,
2372 .subdevice = 0xdc00,
2373 .card = CX88_BOARD_SAMSUNG_SMT_7020,
2374 }, {
2375 .subvendor = 0x18ac,
2376 .subdevice = 0xdccd,
2377 .card = CX88_BOARD_SAMSUNG_SMT_7020,
2379 .subvendor = 0x1461,
2380 .subdevice = 0xc111, /* AverMedia M150-D */
2381 /* This board is known to work with the ASUS PVR416 config */
2382 .card = CX88_BOARD_ASUS_PVR_416,
2384 .subvendor = 0xc180,
2385 .subdevice = 0xc980,
2386 .card = CX88_BOARD_TE_DTV_250_OEM_SWANN,
2388 .subvendor = 0x0070,
2389 .subdevice = 0x9600,
2390 .card = CX88_BOARD_HAUPPAUGE_HVR1300,
2392 .subvendor = 0x0070,
2393 .subdevice = 0x9601,
2394 .card = CX88_BOARD_HAUPPAUGE_HVR1300,
2396 .subvendor = 0x0070,
2397 .subdevice = 0x9602,
2398 .card = CX88_BOARD_HAUPPAUGE_HVR1300,
2400 .subvendor = 0x107d,
2401 .subdevice = 0x6632,
2402 .card = CX88_BOARD_LEADTEK_PVR2000,
2404 .subvendor = 0x12ab,
2405 .subdevice = 0x2300, /* Club3D Zap TV2100 */
2406 .card = CX88_BOARD_KWORLD_DVB_T_CX22702,
2408 .subvendor = 0x0070,
2409 .subdevice = 0x9000,
2410 .card = CX88_BOARD_HAUPPAUGE_DVB_T1,
2412 .subvendor = 0x0070,
2413 .subdevice = 0x1400,
2414 .card = CX88_BOARD_HAUPPAUGE_HVR3000,
2416 .subvendor = 0x0070,
2417 .subdevice = 0x1401,
2418 .card = CX88_BOARD_HAUPPAUGE_HVR3000,
2420 .subvendor = 0x0070,
2421 .subdevice = 0x1402,
2422 .card = CX88_BOARD_HAUPPAUGE_HVR3000,
2424 .subvendor = 0x1421,
2425 .subdevice = 0x0341, /* ADS Tech InstantTV DVB-S */
2426 .card = CX88_BOARD_KWORLD_DVBS_100,
2428 .subvendor = 0x1421,
2429 .subdevice = 0x0390,
2430 .card = CX88_BOARD_ADSTECH_PTV_390,
2432 .subvendor = 0x11bd,
2433 .subdevice = 0x0051,
2434 .card = CX88_BOARD_PINNACLE_PCTV_HD_800i,
2435 }, {
2436 .subvendor = 0x18ac,
2437 .subdevice = 0xd530,
2438 .card = CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO,
2439 }, {
2440 .subvendor = 0x12ab,
2441 .subdevice = 0x1788,
2442 .card = CX88_BOARD_PINNACLE_HYBRID_PCTV,
2443 }, {
2444 .subvendor = 0x14f1,
2445 .subdevice = 0xea3d,
2446 .card = CX88_BOARD_POWERCOLOR_REAL_ANGEL,
2447 }, {
2448 .subvendor = 0x107d,
2449 .subdevice = 0x6f18,
2450 .card = CX88_BOARD_WINFAST_TV2000_XP_GLOBAL,
2451 }, {
2452 .subvendor = 0x14f1,
2453 .subdevice = 0x8852,
2454 .card = CX88_BOARD_GENIATECH_X8000_MT,
2455 }, {
2456 .subvendor = 0x18ac,
2457 .subdevice = 0xd610,
2458 .card = CX88_BOARD_DVICO_FUSIONHDTV_7_GOLD,
2459 }, {
2460 .subvendor = 0x1554,
2461 .subdevice = 0x4935,
2462 .card = CX88_BOARD_PROLINK_PV_8000GT,
2463 }, {
2464 .subvendor = 0x1554,
2465 .subdevice = 0x4976,
2466 .card = CX88_BOARD_PROLINK_PV_GLOBAL_XTREME,
2467 }, {
2468 .subvendor = 0x17de,
2469 .subdevice = 0x08c1,
2470 .card = CX88_BOARD_KWORLD_ATSC_120,
2471 }, {
2472 .subvendor = 0x0070,
2473 .subdevice = 0x6900,
2474 .card = CX88_BOARD_HAUPPAUGE_HVR4000,
2475 }, {
2476 .subvendor = 0x0070,
2477 .subdevice = 0x6904,
2478 .card = CX88_BOARD_HAUPPAUGE_HVR4000,
2479 }, {
2480 .subvendor = 0x0070,
2481 .subdevice = 0x6902,
2482 .card = CX88_BOARD_HAUPPAUGE_HVR4000,
2483 }, {
2484 .subvendor = 0x0070,
2485 .subdevice = 0x6905,
2486 .card = CX88_BOARD_HAUPPAUGE_HVR4000LITE,
2487 }, {
2488 .subvendor = 0x0070,
2489 .subdevice = 0x6906,
2490 .card = CX88_BOARD_HAUPPAUGE_HVR4000LITE,
2491 }, {
2492 .subvendor = 0xd420,
2493 .subdevice = 0x9022,
2494 .card = CX88_BOARD_TEVII_S420,
2495 }, {
2496 .subvendor = 0xd460,
2497 .subdevice = 0x9022,
2498 .card = CX88_BOARD_TEVII_S460,
2499 }, {
2500 .subvendor = 0xA044,
2501 .subdevice = 0x2011,
2502 .card = CX88_BOARD_OMICOM_SS4_PCI,
2503 }, {
2504 .subvendor = 0x8910,
2505 .subdevice = 0x8888,
2506 .card = CX88_BOARD_TBS_8910,
2507 }, {
2508 .subvendor = 0x8920,
2509 .subdevice = 0x8888,
2510 .card = CX88_BOARD_TBS_8920,
2511 }, {
2512 .subvendor = 0xb022,
2513 .subdevice = 0x3022,
2514 .card = CX88_BOARD_PROF_6200,
2515 }, {
2516 .subvendor = 0xB033,
2517 .subdevice = 0x3033,
2518 .card = CX88_BOARD_PROF_7300,
2519 }, {
2520 .subvendor = 0xb200,
2521 .subdevice = 0x4200,
2522 .card = CX88_BOARD_SATTRADE_ST4200,
2523 }, {
2524 .subvendor = 0x153b,
2525 .subdevice = 0x1177,
2526 .card = CX88_BOARD_TERRATEC_CINERGY_HT_PCI_MKII,
2527 }, {
2528 .subvendor = 0x0070,
2529 .subdevice = 0x9290,
2530 .card = CX88_BOARD_HAUPPAUGE_IRONLY,
2531 }, {
2532 .subvendor = 0x107d,
2533 .subdevice = 0x6654,
2534 .card = CX88_BOARD_WINFAST_DTV1800H,
2535 }, {
2536 /* PVR2000 PAL Model [107d:6630] */
2537 .subvendor = 0x107d,
2538 .subdevice = 0x6630,
2539 .card = CX88_BOARD_LEADTEK_PVR2000,
2540 }, {
2541 /* PVR2000 PAL Model [107d:6638] */
2542 .subvendor = 0x107d,
2543 .subdevice = 0x6638,
2544 .card = CX88_BOARD_LEADTEK_PVR2000,
2545 }, {
2546 /* PVR2000 NTSC Model [107d:6631] */
2547 .subvendor = 0x107d,
2548 .subdevice = 0x6631,
2549 .card = CX88_BOARD_LEADTEK_PVR2000,
2550 }, {
2551 /* PVR2000 NTSC Model [107d:6637] */
2552 .subvendor = 0x107d,
2553 .subdevice = 0x6637,
2554 .card = CX88_BOARD_LEADTEK_PVR2000,
2555 }, {
2556 /* PVR2000 NTSC Model [107d:663d] */
2557 .subvendor = 0x107d,
2558 .subdevice = 0x663d,
2559 .card = CX88_BOARD_LEADTEK_PVR2000,
2560 }, {
2561 /* DV2000 NTSC Model [107d:6621] */
2562 .subvendor = 0x107d,
2563 .subdevice = 0x6621,
2564 .card = CX88_BOARD_WINFAST_DV2000,
2565 }, {
2566 /* TV2000 XP Global [107d:6618] */
2567 .subvendor = 0x107d,
2568 .subdevice = 0x6618,
2569 .card = CX88_BOARD_WINFAST_TV2000_XP_GLOBAL,
2570 }, {
2571 .subvendor = 0xb034,
2572 .subdevice = 0x3034,
2573 .card = CX88_BOARD_PROF_7301,
2577 /* ----------------------------------------------------------------------- */
2578 /* some leadtek specific stuff */
2580 static void leadtek_eeprom(struct cx88_core *core, u8 *eeprom_data)
2582 if (eeprom_data[4] != 0x7d ||
2583 eeprom_data[5] != 0x10 ||
2584 eeprom_data[7] != 0x66) {
2585 warn_printk(core, "Leadtek eeprom invalid.\n");
2586 return;
2589 /* Terry Wu <terrywu2009@gmail.com> */
2590 switch (eeprom_data[6]) {
2591 case 0x13: /* SSID 6613 for TV2000 XP Expert NTSC Model */
2592 case 0x21: /* SSID 6621 for DV2000 NTSC Model */
2593 case 0x31: /* SSID 6631 for PVR2000 NTSC Model */
2594 case 0x37: /* SSID 6637 for PVR2000 NTSC Model */
2595 case 0x3d: /* SSID 6637 for PVR2000 NTSC Model */
2596 core->board.tuner_type = TUNER_PHILIPS_FM1236_MK3;
2597 break;
2598 default:
2599 core->board.tuner_type = TUNER_PHILIPS_FM1216ME_MK3;
2600 break;
2603 info_printk(core, "Leadtek Winfast 2000XP Expert config: "
2604 "tuner=%d, eeprom[0]=0x%02x\n",
2605 core->board.tuner_type, eeprom_data[0]);
2608 static void hauppauge_eeprom(struct cx88_core *core, u8 *eeprom_data)
2610 struct tveeprom tv;
2612 tveeprom_hauppauge_analog(&core->i2c_client, &tv, eeprom_data);
2613 core->board.tuner_type = tv.tuner_type;
2614 core->tuner_formats = tv.tuner_formats;
2615 core->board.radio.type = tv.has_radio ? CX88_RADIO : 0;
2617 /* Make sure we support the board model */
2618 switch (tv.model)
2620 case 14009: /* WinTV-HVR3000 (Retail, IR, b/panel video, 3.5mm audio in) */
2621 case 14019: /* WinTV-HVR3000 (Retail, IR Blaster, b/panel video, 3.5mm audio in) */
2622 case 14029: /* WinTV-HVR3000 (Retail, IR, b/panel video, 3.5mm audio in - 880 bridge) */
2623 case 14109: /* WinTV-HVR3000 (Retail, IR, b/panel video, 3.5mm audio in - low profile) */
2624 case 14129: /* WinTV-HVR3000 (Retail, IR, b/panel video, 3.5mm audio in - 880 bridge - LP) */
2625 case 14559: /* WinTV-HVR3000 (OEM, no IR, b/panel video, 3.5mm audio in) */
2626 case 14569: /* WinTV-HVR3000 (OEM, no IR, no back panel video) */
2627 case 14659: /* WinTV-HVR3000 (OEM, no IR, b/panel video, RCA audio in - Low profile) */
2628 case 14669: /* WinTV-HVR3000 (OEM, no IR, no b/panel video - Low profile) */
2629 case 28552: /* WinTV-PVR 'Roslyn' (No IR) */
2630 case 34519: /* WinTV-PCI-FM */
2631 case 69009:
2632 /* WinTV-HVR4000 (DVBS/S2/T, Video and IR, back panel inputs) */
2633 case 69100: /* WinTV-HVR4000LITE (DVBS/S2, IR) */
2634 case 69500: /* WinTV-HVR4000LITE (DVBS/S2, No IR) */
2635 case 69559:
2636 /* WinTV-HVR4000 (DVBS/S2/T, Video no IR, back panel inputs) */
2637 case 69569: /* WinTV-HVR4000 (DVBS/S2/T, Video no IR) */
2638 case 90002: /* Nova-T-PCI (9002) */
2639 case 92001: /* Nova-S-Plus (Video and IR) */
2640 case 92002: /* Nova-S-Plus (Video and IR) */
2641 case 90003: /* Nova-T-PCI (9002 No RF out) */
2642 case 90500: /* Nova-T-PCI (oem) */
2643 case 90501: /* Nova-T-PCI (oem/IR) */
2644 case 92000: /* Nova-SE2 (OEM, No Video or IR) */
2645 case 92900: /* WinTV-IROnly (No analog or digital Video inputs) */
2646 case 94009: /* WinTV-HVR1100 (Video and IR Retail) */
2647 case 94501: /* WinTV-HVR1100 (Video and IR OEM) */
2648 case 96009: /* WinTV-HVR1300 (PAL Video, MPEG Video and IR RX) */
2649 case 96019: /* WinTV-HVR1300 (PAL Video, MPEG Video and IR RX/TX) */
2650 case 96559: /* WinTV-HVR1300 (PAL Video, MPEG Video no IR) */
2651 case 96569: /* WinTV-HVR1300 () */
2652 case 96659: /* WinTV-HVR1300 () */
2653 case 98559: /* WinTV-HVR1100LP (Video no IR, Retail - Low Profile) */
2654 /* known */
2655 break;
2656 case CX88_BOARD_SAMSUNG_SMT_7020:
2657 cx_set(MO_GP0_IO, 0x008989FF);
2658 break;
2659 default:
2660 warn_printk(core, "warning: unknown hauppauge model #%d\n",
2661 tv.model);
2662 break;
2665 info_printk(core, "hauppauge eeprom: model=%d\n", tv.model);
2668 /* ----------------------------------------------------------------------- */
2669 /* some GDI (was: Modular Technology) specific stuff */
2671 static struct {
2672 int id;
2673 int fm;
2674 char *name;
2675 } gdi_tuner[] = {
2676 [ 0x01 ] = { .id = TUNER_ABSENT,
2677 .name = "NTSC_M" },
2678 [ 0x02 ] = { .id = TUNER_ABSENT,
2679 .name = "PAL_B" },
2680 [ 0x03 ] = { .id = TUNER_ABSENT,
2681 .name = "PAL_I" },
2682 [ 0x04 ] = { .id = TUNER_ABSENT,
2683 .name = "PAL_D" },
2684 [ 0x05 ] = { .id = TUNER_ABSENT,
2685 .name = "SECAM" },
2687 [ 0x10 ] = { .id = TUNER_ABSENT,
2688 .fm = 1,
2689 .name = "TEMIC_4049" },
2690 [ 0x11 ] = { .id = TUNER_TEMIC_4136FY5,
2691 .name = "TEMIC_4136" },
2692 [ 0x12 ] = { .id = TUNER_ABSENT,
2693 .name = "TEMIC_4146" },
2695 [ 0x20 ] = { .id = TUNER_PHILIPS_FQ1216ME,
2696 .fm = 1,
2697 .name = "PHILIPS_FQ1216_MK3" },
2698 [ 0x21 ] = { .id = TUNER_ABSENT, .fm = 1,
2699 .name = "PHILIPS_FQ1236_MK3" },
2700 [ 0x22 ] = { .id = TUNER_ABSENT,
2701 .name = "PHILIPS_FI1236_MK3" },
2702 [ 0x23 ] = { .id = TUNER_ABSENT,
2703 .name = "PHILIPS_FI1216_MK3" },
2706 static void gdi_eeprom(struct cx88_core *core, u8 *eeprom_data)
2708 char *name = (eeprom_data[0x0d] < ARRAY_SIZE(gdi_tuner))
2709 ? gdi_tuner[eeprom_data[0x0d]].name : NULL;
2711 info_printk(core, "GDI: tuner=%s\n", name ? name : "unknown");
2712 if (NULL == name)
2713 return;
2714 core->board.tuner_type = gdi_tuner[eeprom_data[0x0d]].id;
2715 core->board.radio.type = gdi_tuner[eeprom_data[0x0d]].fm ?
2716 CX88_RADIO : 0;
2719 /* ------------------------------------------------------------------- */
2720 /* some Divco specific stuff */
2721 static int cx88_dvico_xc2028_callback(struct cx88_core *core,
2722 int command, int arg)
2724 switch (command) {
2725 case XC2028_TUNER_RESET:
2726 switch (core->boardnr) {
2727 case CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO:
2728 /* GPIO-4 xc3028 tuner */
2730 cx_set(MO_GP0_IO, 0x00001000);
2731 cx_clear(MO_GP0_IO, 0x00000010);
2732 msleep(100);
2733 cx_set(MO_GP0_IO, 0x00000010);
2734 msleep(100);
2735 break;
2736 default:
2737 cx_write(MO_GP0_IO, 0x101000);
2738 mdelay(5);
2739 cx_set(MO_GP0_IO, 0x101010);
2741 break;
2742 default:
2743 return -EINVAL;
2746 return 0;
2750 /* ----------------------------------------------------------------------- */
2751 /* some Geniatech specific stuff */
2753 static int cx88_xc3028_geniatech_tuner_callback(struct cx88_core *core,
2754 int command, int mode)
2756 switch (command) {
2757 case XC2028_TUNER_RESET:
2758 switch (INPUT(core->input).type) {
2759 case CX88_RADIO:
2760 break;
2761 case CX88_VMUX_DVB:
2762 cx_write(MO_GP1_IO, 0x030302);
2763 mdelay(50);
2764 break;
2765 default:
2766 cx_write(MO_GP1_IO, 0x030301);
2767 mdelay(50);
2769 cx_write(MO_GP1_IO, 0x101010);
2770 mdelay(50);
2771 cx_write(MO_GP1_IO, 0x101000);
2772 mdelay(50);
2773 cx_write(MO_GP1_IO, 0x101010);
2774 mdelay(50);
2775 return 0;
2777 return -EINVAL;
2780 static int cx88_xc3028_winfast1800h_callback(struct cx88_core *core,
2781 int command, int arg)
2783 switch (command) {
2784 case XC2028_TUNER_RESET:
2785 /* GPIO 12 (xc3028 tuner reset) */
2786 cx_set(MO_GP1_IO, 0x1010);
2787 mdelay(50);
2788 cx_clear(MO_GP1_IO, 0x10);
2789 mdelay(50);
2790 cx_set(MO_GP1_IO, 0x10);
2791 mdelay(50);
2792 return 0;
2794 return -EINVAL;
2797 /* ------------------------------------------------------------------- */
2798 /* some Divco specific stuff */
2799 static int cx88_pv_8000gt_callback(struct cx88_core *core,
2800 int command, int arg)
2802 switch (command) {
2803 case XC2028_TUNER_RESET:
2804 cx_write(MO_GP2_IO, 0xcf7);
2805 mdelay(50);
2806 cx_write(MO_GP2_IO, 0xef5);
2807 mdelay(50);
2808 cx_write(MO_GP2_IO, 0xcf7);
2809 break;
2810 default:
2811 return -EINVAL;
2814 return 0;
2817 /* ----------------------------------------------------------------------- */
2818 /* some DViCO specific stuff */
2820 static void dvico_fusionhdtv_hybrid_init(struct cx88_core *core)
2822 struct i2c_msg msg = { .addr = 0x45, .flags = 0 };
2823 int i, err;
2824 static u8 init_bufs[13][5] = {
2825 { 0x10, 0x00, 0x20, 0x01, 0x03 },
2826 { 0x10, 0x10, 0x01, 0x00, 0x21 },
2827 { 0x10, 0x10, 0x10, 0x00, 0xCA },
2828 { 0x10, 0x10, 0x12, 0x00, 0x08 },
2829 { 0x10, 0x10, 0x13, 0x00, 0x0A },
2830 { 0x10, 0x10, 0x16, 0x01, 0xC0 },
2831 { 0x10, 0x10, 0x22, 0x01, 0x3D },
2832 { 0x10, 0x10, 0x73, 0x01, 0x2E },
2833 { 0x10, 0x10, 0x72, 0x00, 0xC5 },
2834 { 0x10, 0x10, 0x71, 0x01, 0x97 },
2835 { 0x10, 0x10, 0x70, 0x00, 0x0F },
2836 { 0x10, 0x10, 0xB0, 0x00, 0x01 },
2837 { 0x03, 0x0C },
2840 for (i = 0; i < ARRAY_SIZE(init_bufs); i++) {
2841 msg.buf = init_bufs[i];
2842 msg.len = (i != 12 ? 5 : 2);
2843 err = i2c_transfer(&core->i2c_adap, &msg, 1);
2844 if (err != 1) {
2845 warn_printk(core, "dvico_fusionhdtv_hybrid_init buf %d "
2846 "failed (err = %d)!\n", i, err);
2847 return;
2852 static int cx88_xc2028_tuner_callback(struct cx88_core *core,
2853 int command, int arg)
2855 /* Board-specific callbacks */
2856 switch (core->boardnr) {
2857 case CX88_BOARD_POWERCOLOR_REAL_ANGEL:
2858 case CX88_BOARD_GENIATECH_X8000_MT:
2859 case CX88_BOARD_KWORLD_ATSC_120:
2860 return cx88_xc3028_geniatech_tuner_callback(core,
2861 command, arg);
2862 case CX88_BOARD_PROLINK_PV_8000GT:
2863 case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
2864 return cx88_pv_8000gt_callback(core, command, arg);
2865 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO:
2866 case CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO:
2867 return cx88_dvico_xc2028_callback(core, command, arg);
2868 case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
2869 case CX88_BOARD_WINFAST_DTV1800H:
2870 return cx88_xc3028_winfast1800h_callback(core, command, arg);
2873 switch (command) {
2874 case XC2028_TUNER_RESET:
2875 switch (INPUT(core->input).type) {
2876 case CX88_RADIO:
2877 info_printk(core, "setting GPIO to radio!\n");
2878 cx_write(MO_GP0_IO, 0x4ff);
2879 mdelay(250);
2880 cx_write(MO_GP2_IO, 0xff);
2881 mdelay(250);
2882 break;
2883 case CX88_VMUX_DVB: /* Digital TV*/
2884 default: /* Analog TV */
2885 info_printk(core, "setting GPIO to TV!\n");
2886 break;
2888 cx_write(MO_GP1_IO, 0x101010);
2889 mdelay(250);
2890 cx_write(MO_GP1_IO, 0x101000);
2891 mdelay(250);
2892 cx_write(MO_GP1_IO, 0x101010);
2893 mdelay(250);
2894 return 0;
2896 return -EINVAL;
2899 /* ----------------------------------------------------------------------- */
2900 /* Tuner callback function. Currently only needed for the Pinnacle *
2901 * PCTV HD 800i with an xc5000 sillicon tuner. This is used for both *
2902 * analog tuner attach (tuner-core.c) and dvb tuner attach (cx88-dvb.c) */
2904 static int cx88_xc5000_tuner_callback(struct cx88_core *core,
2905 int command, int arg)
2907 switch (core->boardnr) {
2908 case CX88_BOARD_PINNACLE_PCTV_HD_800i:
2909 if (command == 0) { /* This is the reset command from xc5000 */
2911 /* djh - According to the engineer at PCTV Systems,
2912 the xc5000 reset pin is supposed to be on GPIO12.
2913 However, despite three nights of effort, pulling
2914 that GPIO low didn't reset the xc5000. While
2915 pulling MO_SRST_IO low does reset the xc5000, this
2916 also resets in the s5h1409 being reset as well.
2917 This causes tuning to always fail since the internal
2918 state of the s5h1409 does not match the driver's
2919 state. Given that the only two conditions in which
2920 the driver performs a reset is during firmware load
2921 and powering down the chip, I am taking out the
2922 reset. We know that the chip is being reset
2923 when the cx88 comes online, and not being able to
2924 do power management for this board is worse than
2925 not having any tuning at all. */
2926 return 0;
2927 } else {
2928 err_printk(core, "xc5000: unknown tuner "
2929 "callback command.\n");
2930 return -EINVAL;
2932 break;
2933 case CX88_BOARD_DVICO_FUSIONHDTV_7_GOLD:
2934 if (command == 0) { /* This is the reset command from xc5000 */
2935 cx_clear(MO_GP0_IO, 0x00000010);
2936 msleep(10);
2937 cx_set(MO_GP0_IO, 0x00000010);
2938 return 0;
2939 } else {
2940 printk(KERN_ERR
2941 "xc5000: unknown tuner callback command.\n");
2942 return -EINVAL;
2944 break;
2946 return 0; /* Should never be here */
2949 int cx88_tuner_callback(void *priv, int component, int command, int arg)
2951 struct i2c_algo_bit_data *i2c_algo = priv;
2952 struct cx88_core *core;
2954 if (!i2c_algo) {
2955 printk(KERN_ERR "cx88: Error - i2c private data undefined.\n");
2956 return -EINVAL;
2959 core = i2c_algo->data;
2961 if (!core) {
2962 printk(KERN_ERR "cx88: Error - device struct undefined.\n");
2963 return -EINVAL;
2966 if (component != DVB_FRONTEND_COMPONENT_TUNER)
2967 return -EINVAL;
2969 switch (core->board.tuner_type) {
2970 case TUNER_XC2028:
2971 info_printk(core, "Calling XC2028/3028 callback\n");
2972 return cx88_xc2028_tuner_callback(core, command, arg);
2973 case TUNER_XC5000:
2974 info_printk(core, "Calling XC5000 callback\n");
2975 return cx88_xc5000_tuner_callback(core, command, arg);
2977 err_printk(core, "Error: Calling callback for tuner %d\n",
2978 core->board.tuner_type);
2979 return -EINVAL;
2981 EXPORT_SYMBOL(cx88_tuner_callback);
2983 /* ----------------------------------------------------------------------- */
2985 static void cx88_card_list(struct cx88_core *core, struct pci_dev *pci)
2987 int i;
2989 if (0 == pci->subsystem_vendor &&
2990 0 == pci->subsystem_device) {
2991 printk(KERN_ERR
2992 "%s: Your board has no valid PCI Subsystem ID and thus can't\n"
2993 "%s: be autodetected. Please pass card=<n> insmod option to\n"
2994 "%s: workaround that. Redirect complaints to the vendor of\n"
2995 "%s: the TV card. Best regards,\n"
2996 "%s: -- tux\n",
2997 core->name,core->name,core->name,core->name,core->name);
2998 } else {
2999 printk(KERN_ERR
3000 "%s: Your board isn't known (yet) to the driver. You can\n"
3001 "%s: try to pick one of the existing card configs via\n"
3002 "%s: card=<n> insmod option. Updating to the latest\n"
3003 "%s: version might help as well.\n",
3004 core->name,core->name,core->name,core->name);
3006 err_printk(core, "Here is a list of valid choices for the card=<n> "
3007 "insmod option:\n");
3008 for (i = 0; i < ARRAY_SIZE(cx88_boards); i++)
3009 printk(KERN_ERR "%s: card=%d -> %s\n",
3010 core->name, i, cx88_boards[i].name);
3013 static void cx88_card_setup_pre_i2c(struct cx88_core *core)
3015 switch (core->boardnr) {
3016 case CX88_BOARD_HAUPPAUGE_HVR1300:
3018 * Bring the 702 demod up before i2c scanning/attach or devices are hidden
3019 * We leave here with the 702 on the bus
3021 * "reset the IR receiver on GPIO[3]"
3022 * Reported by Mike Crash <mike AT mikecrash.com>
3024 cx_write(MO_GP0_IO, 0x0000ef88);
3025 udelay(1000);
3026 cx_clear(MO_GP0_IO, 0x00000088);
3027 udelay(50);
3028 cx_set(MO_GP0_IO, 0x00000088); /* 702 out of reset */
3029 udelay(1000);
3030 break;
3032 case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
3033 case CX88_BOARD_PROLINK_PV_8000GT:
3034 cx_write(MO_GP2_IO, 0xcf7);
3035 mdelay(50);
3036 cx_write(MO_GP2_IO, 0xef5);
3037 mdelay(50);
3038 cx_write(MO_GP2_IO, 0xcf7);
3039 msleep(10);
3040 break;
3042 case CX88_BOARD_DVICO_FUSIONHDTV_7_GOLD:
3043 /* Enable the xc5000 tuner */
3044 cx_set(MO_GP0_IO, 0x00001010);
3045 break;
3047 case CX88_BOARD_HAUPPAUGE_HVR3000:
3048 case CX88_BOARD_HAUPPAUGE_HVR4000:
3049 /* Init GPIO */
3050 cx_write(MO_GP0_IO, core->board.input[0].gpio0);
3051 udelay(1000);
3052 cx_clear(MO_GP0_IO, 0x00000080);
3053 udelay(50);
3054 cx_set(MO_GP0_IO, 0x00000080); /* 702 out of reset */
3055 udelay(1000);
3056 break;
3058 case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
3059 case CX88_BOARD_WINFAST_DTV1800H:
3060 /* GPIO 12 (xc3028 tuner reset) */
3061 cx_set(MO_GP1_IO, 0x1010);
3062 mdelay(50);
3063 cx_clear(MO_GP1_IO, 0x10);
3064 mdelay(50);
3065 cx_set(MO_GP1_IO, 0x10);
3066 mdelay(50);
3067 break;
3072 * Sets board-dependent xc3028 configuration
3074 void cx88_setup_xc3028(struct cx88_core *core, struct xc2028_ctrl *ctl)
3076 memset(ctl, 0, sizeof(*ctl));
3078 ctl->fname = XC2028_DEFAULT_FIRMWARE;
3079 ctl->max_len = 64;
3081 switch (core->boardnr) {
3082 case CX88_BOARD_POWERCOLOR_REAL_ANGEL:
3083 /* Now works with firmware version 2.7 */
3084 if (core->i2c_algo.udelay < 16)
3085 core->i2c_algo.udelay = 16;
3086 break;
3087 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO:
3088 case CX88_BOARD_WINFAST_DTV1800H:
3089 ctl->demod = XC3028_FE_ZARLINK456;
3090 break;
3091 case CX88_BOARD_KWORLD_ATSC_120:
3092 case CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO:
3093 ctl->demod = XC3028_FE_OREN538;
3094 break;
3095 case CX88_BOARD_GENIATECH_X8000_MT:
3096 ctl->disable_power_mgmt = 1;
3097 break;
3098 case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
3099 case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
3100 case CX88_BOARD_PROLINK_PV_8000GT:
3102 * Those boards uses non-MTS firmware
3104 break;
3105 case CX88_BOARD_PINNACLE_HYBRID_PCTV:
3106 case CX88_BOARD_TERRATEC_CINERGY_HT_PCI_MKII:
3107 ctl->demod = XC3028_FE_ZARLINK456;
3108 ctl->mts = 1;
3109 break;
3110 default:
3111 ctl->demod = XC3028_FE_OREN538;
3112 ctl->mts = 1;
3115 EXPORT_SYMBOL_GPL(cx88_setup_xc3028);
3117 static void cx88_card_setup(struct cx88_core *core)
3119 static u8 eeprom[256];
3120 struct tuner_setup tun_setup;
3121 unsigned int mode_mask = T_RADIO |
3122 T_ANALOG_TV |
3123 T_DIGITAL_TV;
3125 memset(&tun_setup, 0, sizeof(tun_setup));
3127 if (0 == core->i2c_rc) {
3128 core->i2c_client.addr = 0xa0 >> 1;
3129 tveeprom_read(&core->i2c_client, eeprom, sizeof(eeprom));
3132 switch (core->boardnr) {
3133 case CX88_BOARD_HAUPPAUGE:
3134 case CX88_BOARD_HAUPPAUGE_ROSLYN:
3135 if (0 == core->i2c_rc)
3136 hauppauge_eeprom(core, eeprom+8);
3137 break;
3138 case CX88_BOARD_GDI:
3139 if (0 == core->i2c_rc)
3140 gdi_eeprom(core, eeprom);
3141 break;
3142 case CX88_BOARD_LEADTEK_PVR2000:
3143 case CX88_BOARD_WINFAST_DV2000:
3144 case CX88_BOARD_WINFAST2000XP_EXPERT:
3145 if (0 == core->i2c_rc)
3146 leadtek_eeprom(core, eeprom);
3147 break;
3148 case CX88_BOARD_HAUPPAUGE_NOVASPLUS_S1:
3149 case CX88_BOARD_HAUPPAUGE_NOVASE2_S1:
3150 case CX88_BOARD_HAUPPAUGE_DVB_T1:
3151 case CX88_BOARD_HAUPPAUGE_HVR1100:
3152 case CX88_BOARD_HAUPPAUGE_HVR1100LP:
3153 case CX88_BOARD_HAUPPAUGE_HVR3000:
3154 case CX88_BOARD_HAUPPAUGE_HVR1300:
3155 case CX88_BOARD_HAUPPAUGE_HVR4000:
3156 case CX88_BOARD_HAUPPAUGE_HVR4000LITE:
3157 case CX88_BOARD_HAUPPAUGE_IRONLY:
3158 if (0 == core->i2c_rc)
3159 hauppauge_eeprom(core, eeprom);
3160 break;
3161 case CX88_BOARD_KWORLD_DVBS_100:
3162 cx_write(MO_GP0_IO, 0x000007f8);
3163 cx_write(MO_GP1_IO, 0x00000001);
3164 break;
3165 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PRO:
3166 /* GPIO0:0 is hooked to demod reset */
3167 /* GPIO0:4 is hooked to xc3028 reset */
3168 cx_write(MO_GP0_IO, 0x00111100);
3169 msleep(1);
3170 cx_write(MO_GP0_IO, 0x00111111);
3171 break;
3172 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL:
3173 /* GPIO0:6 is hooked to FX2 reset pin */
3174 cx_set(MO_GP0_IO, 0x00004040);
3175 cx_clear(MO_GP0_IO, 0x00000040);
3176 msleep(1000);
3177 cx_set(MO_GP0_IO, 0x00004040);
3178 /* FALLTHROUGH */
3179 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1:
3180 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS:
3181 case CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_HYBRID:
3182 /* GPIO0:0 is hooked to mt352 reset pin */
3183 cx_set(MO_GP0_IO, 0x00000101);
3184 cx_clear(MO_GP0_IO, 0x00000001);
3185 msleep(1);
3186 cx_set(MO_GP0_IO, 0x00000101);
3187 if (0 == core->i2c_rc &&
3188 core->boardnr == CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_HYBRID)
3189 dvico_fusionhdtv_hybrid_init(core);
3190 break;
3191 case CX88_BOARD_KWORLD_DVB_T:
3192 case CX88_BOARD_DNTV_LIVE_DVB_T:
3193 cx_set(MO_GP0_IO, 0x00000707);
3194 cx_set(MO_GP2_IO, 0x00000101);
3195 cx_clear(MO_GP2_IO, 0x00000001);
3196 msleep(1);
3197 cx_clear(MO_GP0_IO, 0x00000007);
3198 cx_set(MO_GP2_IO, 0x00000101);
3199 break;
3200 case CX88_BOARD_DNTV_LIVE_DVB_T_PRO:
3201 cx_write(MO_GP0_IO, 0x00080808);
3202 break;
3203 case CX88_BOARD_ATI_HDTVWONDER:
3204 if (0 == core->i2c_rc) {
3205 /* enable tuner */
3206 int i;
3207 static const u8 buffer [][2] = {
3208 {0x10,0x12},
3209 {0x13,0x04},
3210 {0x16,0x00},
3211 {0x14,0x04},
3212 {0x17,0x00}
3214 core->i2c_client.addr = 0x0a;
3216 for (i = 0; i < ARRAY_SIZE(buffer); i++)
3217 if (2 != i2c_master_send(&core->i2c_client,
3218 buffer[i],2))
3219 warn_printk(core, "Unable to enable "
3220 "tuner(%i).\n", i);
3222 break;
3223 case CX88_BOARD_MSI_TVANYWHERE_MASTER:
3225 struct v4l2_priv_tun_config tea5767_cfg;
3226 struct tea5767_ctrl ctl;
3228 memset(&ctl, 0, sizeof(ctl));
3230 ctl.high_cut = 1;
3231 ctl.st_noise = 1;
3232 ctl.deemph_75 = 1;
3233 ctl.xtal_freq = TEA5767_HIGH_LO_13MHz;
3235 tea5767_cfg.tuner = TUNER_TEA5767;
3236 tea5767_cfg.priv = &ctl;
3238 call_all(core, tuner, s_config, &tea5767_cfg);
3239 break;
3241 case CX88_BOARD_TEVII_S420:
3242 case CX88_BOARD_TEVII_S460:
3243 case CX88_BOARD_OMICOM_SS4_PCI:
3244 case CX88_BOARD_TBS_8910:
3245 case CX88_BOARD_TBS_8920:
3246 case CX88_BOARD_PROF_6200:
3247 case CX88_BOARD_PROF_7300:
3248 case CX88_BOARD_PROF_7301:
3249 case CX88_BOARD_SATTRADE_ST4200:
3250 cx_write(MO_GP0_IO, 0x8000);
3251 msleep(100);
3252 cx_write(MO_SRST_IO, 0);
3253 msleep(10);
3254 cx_write(MO_GP0_IO, 0x8080);
3255 msleep(100);
3256 cx_write(MO_SRST_IO, 1);
3257 msleep(100);
3258 break;
3259 } /*end switch() */
3262 /* Setup tuners */
3263 if ((core->board.radio_type != UNSET)) {
3264 tun_setup.mode_mask = T_RADIO;
3265 tun_setup.type = core->board.radio_type;
3266 tun_setup.addr = core->board.radio_addr;
3267 tun_setup.tuner_callback = cx88_tuner_callback;
3268 call_all(core, tuner, s_type_addr, &tun_setup);
3269 mode_mask &= ~T_RADIO;
3272 if (core->board.tuner_type != TUNER_ABSENT) {
3273 tun_setup.mode_mask = mode_mask;
3274 tun_setup.type = core->board.tuner_type;
3275 tun_setup.addr = core->board.tuner_addr;
3276 tun_setup.tuner_callback = cx88_tuner_callback;
3278 call_all(core, tuner, s_type_addr, &tun_setup);
3281 if (core->board.tda9887_conf) {
3282 struct v4l2_priv_tun_config tda9887_cfg;
3284 tda9887_cfg.tuner = TUNER_TDA9887;
3285 tda9887_cfg.priv = &core->board.tda9887_conf;
3287 call_all(core, tuner, s_config, &tda9887_cfg);
3290 if (core->board.tuner_type == TUNER_XC2028) {
3291 struct v4l2_priv_tun_config xc2028_cfg;
3292 struct xc2028_ctrl ctl;
3294 /* Fills device-dependent initialization parameters */
3295 cx88_setup_xc3028(core, &ctl);
3297 /* Sends parameters to xc2028/3028 tuner */
3298 memset(&xc2028_cfg, 0, sizeof(xc2028_cfg));
3299 xc2028_cfg.tuner = TUNER_XC2028;
3300 xc2028_cfg.priv = &ctl;
3301 info_printk(core, "Asking xc2028/3028 to load firmware %s\n",
3302 ctl.fname);
3303 call_all(core, tuner, s_config, &xc2028_cfg);
3305 call_all(core, core, s_power, 0);
3308 /* ------------------------------------------------------------------ */
3310 static int cx88_pci_quirks(const char *name, struct pci_dev *pci)
3312 unsigned int lat = UNSET;
3313 u8 ctrl = 0;
3314 u8 value;
3316 /* check pci quirks */
3317 if (pci_pci_problems & PCIPCI_TRITON) {
3318 printk(KERN_INFO "%s: quirk: PCIPCI_TRITON -- set TBFX\n",
3319 name);
3320 ctrl |= CX88X_EN_TBFX;
3322 if (pci_pci_problems & PCIPCI_NATOMA) {
3323 printk(KERN_INFO "%s: quirk: PCIPCI_NATOMA -- set TBFX\n",
3324 name);
3325 ctrl |= CX88X_EN_TBFX;
3327 if (pci_pci_problems & PCIPCI_VIAETBF) {
3328 printk(KERN_INFO "%s: quirk: PCIPCI_VIAETBF -- set TBFX\n",
3329 name);
3330 ctrl |= CX88X_EN_TBFX;
3332 if (pci_pci_problems & PCIPCI_VSFX) {
3333 printk(KERN_INFO "%s: quirk: PCIPCI_VSFX -- set VSFX\n",
3334 name);
3335 ctrl |= CX88X_EN_VSFX;
3337 #ifdef PCIPCI_ALIMAGIK
3338 if (pci_pci_problems & PCIPCI_ALIMAGIK) {
3339 printk(KERN_INFO "%s: quirk: PCIPCI_ALIMAGIK -- latency fixup\n",
3340 name);
3341 lat = 0x0A;
3343 #endif
3345 /* check insmod options */
3346 if (UNSET != latency)
3347 lat = latency;
3349 /* apply stuff */
3350 if (ctrl) {
3351 pci_read_config_byte(pci, CX88X_DEVCTRL, &value);
3352 value |= ctrl;
3353 pci_write_config_byte(pci, CX88X_DEVCTRL, value);
3355 if (UNSET != lat) {
3356 printk(KERN_INFO "%s: setting pci latency timer to %d\n",
3357 name, latency);
3358 pci_write_config_byte(pci, PCI_LATENCY_TIMER, latency);
3360 return 0;
3363 int cx88_get_resources(const struct cx88_core *core, struct pci_dev *pci)
3365 if (request_mem_region(pci_resource_start(pci,0),
3366 pci_resource_len(pci,0),
3367 core->name))
3368 return 0;
3369 printk(KERN_ERR
3370 "%s/%d: Can't get MMIO memory @ 0x%llx, subsystem: %04x:%04x\n",
3371 core->name, PCI_FUNC(pci->devfn),
3372 (unsigned long long)pci_resource_start(pci, 0),
3373 pci->subsystem_vendor, pci->subsystem_device);
3374 return -EBUSY;
3377 /* Allocate and initialize the cx88 core struct. One should hold the
3378 * devlist mutex before calling this. */
3379 struct cx88_core *cx88_core_create(struct pci_dev *pci, int nr)
3381 struct cx88_core *core;
3382 int i;
3384 core = kzalloc(sizeof(*core), GFP_KERNEL);
3385 if (core == NULL)
3386 return NULL;
3388 atomic_inc(&core->refcount);
3389 core->pci_bus = pci->bus->number;
3390 core->pci_slot = PCI_SLOT(pci->devfn);
3391 core->pci_irqmask = PCI_INT_RISC_RD_BERRINT | PCI_INT_RISC_WR_BERRINT |
3392 PCI_INT_BRDG_BERRINT | PCI_INT_SRC_DMA_BERRINT |
3393 PCI_INT_DST_DMA_BERRINT | PCI_INT_IPB_DMA_BERRINT;
3394 mutex_init(&core->lock);
3396 core->nr = nr;
3397 sprintf(core->name, "cx88[%d]", core->nr);
3399 strcpy(core->v4l2_dev.name, core->name);
3400 if (v4l2_device_register(NULL, &core->v4l2_dev)) {
3401 kfree(core);
3402 return NULL;
3405 if (0 != cx88_get_resources(core, pci)) {
3406 v4l2_device_unregister(&core->v4l2_dev);
3407 kfree(core);
3408 return NULL;
3411 /* PCI stuff */
3412 cx88_pci_quirks(core->name, pci);
3413 core->lmmio = ioremap(pci_resource_start(pci, 0),
3414 pci_resource_len(pci, 0));
3415 core->bmmio = (u8 __iomem *)core->lmmio;
3417 if (core->lmmio == NULL) {
3418 kfree(core);
3419 return NULL;
3422 /* board config */
3423 core->boardnr = UNSET;
3424 if (card[core->nr] < ARRAY_SIZE(cx88_boards))
3425 core->boardnr = card[core->nr];
3426 for (i = 0; UNSET == core->boardnr && i < ARRAY_SIZE(cx88_subids); i++)
3427 if (pci->subsystem_vendor == cx88_subids[i].subvendor &&
3428 pci->subsystem_device == cx88_subids[i].subdevice)
3429 core->boardnr = cx88_subids[i].card;
3430 if (UNSET == core->boardnr) {
3431 core->boardnr = CX88_BOARD_UNKNOWN;
3432 cx88_card_list(core, pci);
3435 memcpy(&core->board, &cx88_boards[core->boardnr], sizeof(core->board));
3437 if (!core->board.num_frontends && (core->board.mpeg & CX88_MPEG_DVB))
3438 core->board.num_frontends = 1;
3440 info_printk(core, "subsystem: %04x:%04x, board: %s [card=%d,%s], frontend(s): %d\n",
3441 pci->subsystem_vendor, pci->subsystem_device, core->board.name,
3442 core->boardnr, card[core->nr] == core->boardnr ?
3443 "insmod option" : "autodetected",
3444 core->board.num_frontends);
3446 if (tuner[core->nr] != UNSET)
3447 core->board.tuner_type = tuner[core->nr];
3448 if (radio[core->nr] != UNSET)
3449 core->board.radio_type = radio[core->nr];
3451 info_printk(core, "TV tuner type %d, Radio tuner type %d\n",
3452 core->board.tuner_type, core->board.radio_type);
3454 /* init hardware */
3455 cx88_reset(core);
3456 cx88_card_setup_pre_i2c(core);
3457 cx88_i2c_init(core, pci);
3459 /* load tuner module, if needed */
3460 if (TUNER_ABSENT != core->board.tuner_type) {
3461 /* Ignore 0x6b and 0x6f on cx88 boards.
3462 * FusionHDTV5 RT Gold has an ir receiver at 0x6b
3463 * and an RTC at 0x6f which can get corrupted if probed. */
3464 static const unsigned short tv_addrs[] = {
3465 0x42, 0x43, 0x4a, 0x4b, /* tda8290 */
3466 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67,
3467 0x68, 0x69, 0x6a, 0x6c, 0x6d, 0x6e,
3468 I2C_CLIENT_END
3470 int has_demod = (core->board.tda9887_conf & TDA9887_PRESENT);
3472 /* I don't trust the radio_type as is stored in the card
3473 definitions, so we just probe for it.
3474 The radio_type is sometimes missing, or set to UNSET but
3475 later code configures a tea5767.
3477 v4l2_i2c_new_subdev(&core->v4l2_dev, &core->i2c_adap,
3478 "tuner", "tuner",
3479 0, v4l2_i2c_tuner_addrs(ADDRS_RADIO));
3480 if (has_demod)
3481 v4l2_i2c_new_subdev(&core->v4l2_dev,
3482 &core->i2c_adap, "tuner", "tuner",
3483 0, v4l2_i2c_tuner_addrs(ADDRS_DEMOD));
3484 if (core->board.tuner_addr == ADDR_UNSET) {
3485 v4l2_i2c_new_subdev(&core->v4l2_dev,
3486 &core->i2c_adap, "tuner", "tuner",
3487 0, has_demod ? tv_addrs + 4 : tv_addrs);
3488 } else {
3489 v4l2_i2c_new_subdev(&core->v4l2_dev, &core->i2c_adap,
3490 "tuner", "tuner", core->board.tuner_addr, NULL);
3494 cx88_card_setup(core);
3495 if (!disable_ir) {
3496 cx88_i2c_init_ir(core);
3497 cx88_ir_init(core, pci);
3500 return core;