aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/pci/cx88
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2014-08-29 06:45:00 -0400
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2014-11-03 05:35:34 -0500
commitc39ba330322ba087f4c814f641d1818137c98e95 (patch)
treee63a7f5d8152f0244c93e855205962275584d42f /drivers/media/pci/cx88
parent078859a3230c123ed9cb798fb1cd7f89b4fde102 (diff)
[media] cx88: consistently use UNSET for absent tuner
Don't mix UNSET and TUNER_ABSENT: you have to pick one or the other. For this driver selecting UNSET to represent an absent tuner resulting in the fewest changes. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/pci/cx88')
-rw-r--r--drivers/media/pci/cx88/cx88-cards.c66
-rw-r--r--drivers/media/pci/cx88/cx88-video.c2
2 files changed, 34 insertions, 34 deletions
diff --git a/drivers/media/pci/cx88/cx88-cards.c b/drivers/media/pci/cx88/cx88-cards.c
index 6db654990263..8f2556ec3971 100644
--- a/drivers/media/pci/cx88/cx88-cards.c
+++ b/drivers/media/pci/cx88/cx88-cards.c
@@ -347,7 +347,7 @@ static const struct cx88_board cx88_boards[] = {
347 }, 347 },
348 [CX88_BOARD_IODATA_GVVCP3PCI] = { 348 [CX88_BOARD_IODATA_GVVCP3PCI] = {
349 .name = "IODATA GV-VCP3/PCI", 349 .name = "IODATA GV-VCP3/PCI",
350 .tuner_type = TUNER_ABSENT, 350 .tuner_type = UNSET,
351 .radio_type = UNSET, 351 .radio_type = UNSET,
352 .tuner_addr = ADDR_UNSET, 352 .tuner_addr = ADDR_UNSET,
353 .radio_addr = ADDR_UNSET, 353 .radio_addr = ADDR_UNSET,
@@ -436,7 +436,7 @@ static const struct cx88_board cx88_boards[] = {
436 }, 436 },
437 [CX88_BOARD_KWORLD_DVB_T] = { 437 [CX88_BOARD_KWORLD_DVB_T] = {
438 .name = "KWorld/VStream XPert DVB-T", 438 .name = "KWorld/VStream XPert DVB-T",
439 .tuner_type = TUNER_ABSENT, 439 .tuner_type = UNSET,
440 .radio_type = UNSET, 440 .radio_type = UNSET,
441 .tuner_addr = ADDR_UNSET, 441 .tuner_addr = ADDR_UNSET,
442 .radio_addr = ADDR_UNSET, 442 .radio_addr = ADDR_UNSET,
@@ -455,7 +455,7 @@ static const struct cx88_board cx88_boards[] = {
455 }, 455 },
456 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1] = { 456 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T1] = {
457 .name = "DViCO FusionHDTV DVB-T1", 457 .name = "DViCO FusionHDTV DVB-T1",
458 .tuner_type = TUNER_ABSENT, /* No analog tuner */ 458 .tuner_type = UNSET, /* No analog tuner */
459 .radio_type = UNSET, 459 .radio_type = UNSET,
460 .tuner_addr = ADDR_UNSET, 460 .tuner_addr = ADDR_UNSET,
461 .radio_addr = ADDR_UNSET, 461 .radio_addr = ADDR_UNSET,
@@ -542,7 +542,7 @@ static const struct cx88_board cx88_boards[] = {
542 }, 542 },
543 [CX88_BOARD_HAUPPAUGE_DVB_T1] = { 543 [CX88_BOARD_HAUPPAUGE_DVB_T1] = {
544 .name = "Hauppauge Nova-T DVB-T", 544 .name = "Hauppauge Nova-T DVB-T",
545 .tuner_type = TUNER_ABSENT, 545 .tuner_type = UNSET,
546 .radio_type = UNSET, 546 .radio_type = UNSET,
547 .tuner_addr = ADDR_UNSET, 547 .tuner_addr = ADDR_UNSET,
548 .radio_addr = ADDR_UNSET, 548 .radio_addr = ADDR_UNSET,
@@ -554,7 +554,7 @@ static const struct cx88_board cx88_boards[] = {
554 }, 554 },
555 [CX88_BOARD_CONEXANT_DVB_T1] = { 555 [CX88_BOARD_CONEXANT_DVB_T1] = {
556 .name = "Conexant DVB-T reference design", 556 .name = "Conexant DVB-T reference design",
557 .tuner_type = TUNER_ABSENT, 557 .tuner_type = UNSET,
558 .radio_type = UNSET, 558 .radio_type = UNSET,
559 .tuner_addr = ADDR_UNSET, 559 .tuner_addr = ADDR_UNSET,
560 .radio_addr = ADDR_UNSET, 560 .radio_addr = ADDR_UNSET,
@@ -579,7 +579,7 @@ static const struct cx88_board cx88_boards[] = {
579 }, 579 },
580 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS] = { 580 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_PLUS] = {
581 .name = "DViCO FusionHDTV DVB-T Plus", 581 .name = "DViCO FusionHDTV DVB-T Plus",
582 .tuner_type = TUNER_ABSENT, /* No analog tuner */ 582 .tuner_type = UNSET, /* No analog tuner */
583 .radio_type = UNSET, 583 .radio_type = UNSET,
584 .tuner_addr = ADDR_UNSET, 584 .tuner_addr = ADDR_UNSET,
585 .radio_addr = ADDR_UNSET, 585 .radio_addr = ADDR_UNSET,
@@ -596,7 +596,7 @@ static const struct cx88_board cx88_boards[] = {
596 }, 596 },
597 [CX88_BOARD_DNTV_LIVE_DVB_T] = { 597 [CX88_BOARD_DNTV_LIVE_DVB_T] = {
598 .name = "digitalnow DNTV Live! DVB-T", 598 .name = "digitalnow DNTV Live! DVB-T",
599 .tuner_type = TUNER_ABSENT, 599 .tuner_type = UNSET,
600 .radio_type = UNSET, 600 .radio_type = UNSET,
601 .tuner_addr = ADDR_UNSET, 601 .tuner_addr = ADDR_UNSET,
602 .radio_addr = ADDR_UNSET, 602 .radio_addr = ADDR_UNSET,
@@ -787,7 +787,7 @@ static const struct cx88_board cx88_boards[] = {
787 }, 787 },
788 [CX88_BOARD_ADSTECH_DVB_T_PCI] = { 788 [CX88_BOARD_ADSTECH_DVB_T_PCI] = {
789 .name = "ADS Tech Instant TV DVB-T PCI", 789 .name = "ADS Tech Instant TV DVB-T PCI",
790 .tuner_type = TUNER_ABSENT, 790 .tuner_type = UNSET,
791 .radio_type = UNSET, 791 .radio_type = UNSET,
792 .tuner_addr = ADDR_UNSET, 792 .tuner_addr = ADDR_UNSET,
793 .radio_addr = ADDR_UNSET, 793 .radio_addr = ADDR_UNSET,
@@ -806,7 +806,7 @@ static const struct cx88_board cx88_boards[] = {
806 }, 806 },
807 [CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1] = { 807 [CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1] = {
808 .name = "TerraTec Cinergy 1400 DVB-T", 808 .name = "TerraTec Cinergy 1400 DVB-T",
809 .tuner_type = TUNER_ABSENT, 809 .tuner_type = UNSET,
810 .input = { { 810 .input = { {
811 .type = CX88_VMUX_DVB, 811 .type = CX88_VMUX_DVB,
812 .vmux = 0, 812 .vmux = 0,
@@ -924,7 +924,7 @@ static const struct cx88_board cx88_boards[] = {
924 }, 924 },
925 [CX88_BOARD_WINFAST_DTV1000] = { 925 [CX88_BOARD_WINFAST_DTV1000] = {
926 .name = "WinFast DTV1000-T", 926 .name = "WinFast DTV1000-T",
927 .tuner_type = TUNER_ABSENT, 927 .tuner_type = UNSET,
928 .radio_type = UNSET, 928 .radio_type = UNSET,
929 .tuner_addr = ADDR_UNSET, 929 .tuner_addr = ADDR_UNSET,
930 .radio_addr = ADDR_UNSET, 930 .radio_addr = ADDR_UNSET,
@@ -972,7 +972,7 @@ static const struct cx88_board cx88_boards[] = {
972 }, 972 },
973 [CX88_BOARD_HAUPPAUGE_NOVASPLUS_S1] = { 973 [CX88_BOARD_HAUPPAUGE_NOVASPLUS_S1] = {
974 .name = "Hauppauge Nova-S-Plus DVB-S", 974 .name = "Hauppauge Nova-S-Plus DVB-S",
975 .tuner_type = TUNER_ABSENT, 975 .tuner_type = UNSET,
976 .radio_type = UNSET, 976 .radio_type = UNSET,
977 .tuner_addr = ADDR_UNSET, 977 .tuner_addr = ADDR_UNSET,
978 .radio_addr = ADDR_UNSET, 978 .radio_addr = ADDR_UNSET,
@@ -998,7 +998,7 @@ static const struct cx88_board cx88_boards[] = {
998 }, 998 },
999 [CX88_BOARD_HAUPPAUGE_NOVASE2_S1] = { 999 [CX88_BOARD_HAUPPAUGE_NOVASE2_S1] = {
1000 .name = "Hauppauge Nova-SE2 DVB-S", 1000 .name = "Hauppauge Nova-SE2 DVB-S",
1001 .tuner_type = TUNER_ABSENT, 1001 .tuner_type = UNSET,
1002 .radio_type = UNSET, 1002 .radio_type = UNSET,
1003 .tuner_addr = ADDR_UNSET, 1003 .tuner_addr = ADDR_UNSET,
1004 .radio_addr = ADDR_UNSET, 1004 .radio_addr = ADDR_UNSET,
@@ -1010,7 +1010,7 @@ static const struct cx88_board cx88_boards[] = {
1010 }, 1010 },
1011 [CX88_BOARD_KWORLD_DVBS_100] = { 1011 [CX88_BOARD_KWORLD_DVBS_100] = {
1012 .name = "KWorld DVB-S 100", 1012 .name = "KWorld DVB-S 100",
1013 .tuner_type = TUNER_ABSENT, 1013 .tuner_type = UNSET,
1014 .radio_type = UNSET, 1014 .radio_type = UNSET,
1015 .tuner_addr = ADDR_UNSET, 1015 .tuner_addr = ADDR_UNSET,
1016 .radio_addr = ADDR_UNSET, 1016 .radio_addr = ADDR_UNSET,
@@ -1102,7 +1102,7 @@ static const struct cx88_board cx88_boards[] = {
1102 /* DTT 7579 Conexant CX22702-19 Conexant CX2388x */ 1102 /* DTT 7579 Conexant CX22702-19 Conexant CX2388x */
1103 /* Manenti Marco <marco_manenti@colman.it> */ 1103 /* Manenti Marco <marco_manenti@colman.it> */
1104 .name = "KWorld/VStream XPert DVB-T with cx22702", 1104 .name = "KWorld/VStream XPert DVB-T with cx22702",
1105 .tuner_type = TUNER_ABSENT, 1105 .tuner_type = UNSET,
1106 .radio_type = UNSET, 1106 .radio_type = UNSET,
1107 .tuner_addr = ADDR_UNSET, 1107 .tuner_addr = ADDR_UNSET,
1108 .radio_addr = ADDR_UNSET, 1108 .radio_addr = ADDR_UNSET,
@@ -1121,7 +1121,7 @@ static const struct cx88_board cx88_boards[] = {
1121 }, 1121 },
1122 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL] = { 1122 [CX88_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL] = {
1123 .name = "DViCO FusionHDTV DVB-T Dual Digital", 1123 .name = "DViCO FusionHDTV DVB-T Dual Digital",
1124 .tuner_type = TUNER_ABSENT, /* No analog tuner */ 1124 .tuner_type = UNSET, /* No analog tuner */
1125 .radio_type = UNSET, 1125 .radio_type = UNSET,
1126 .tuner_addr = ADDR_UNSET, 1126 .tuner_addr = ADDR_UNSET,
1127 .radio_addr = ADDR_UNSET, 1127 .radio_addr = ADDR_UNSET,
@@ -1356,7 +1356,7 @@ static const struct cx88_board cx88_boards[] = {
1356 }, 1356 },
1357 [CX88_BOARD_GENIATECH_DVBS] = { 1357 [CX88_BOARD_GENIATECH_DVBS] = {
1358 .name = "Geniatech DVB-S", 1358 .name = "Geniatech DVB-S",
1359 .tuner_type = TUNER_ABSENT, 1359 .tuner_type = UNSET,
1360 .radio_type = UNSET, 1360 .radio_type = UNSET,
1361 .tuner_addr = ADDR_UNSET, 1361 .tuner_addr = ADDR_UNSET,
1362 .radio_addr = ADDR_UNSET, 1362 .radio_addr = ADDR_UNSET,
@@ -1494,7 +1494,7 @@ static const struct cx88_board cx88_boards[] = {
1494 }, 1494 },
1495 [CX88_BOARD_SAMSUNG_SMT_7020] = { 1495 [CX88_BOARD_SAMSUNG_SMT_7020] = {
1496 .name = "Samsung SMT 7020 DVB-S", 1496 .name = "Samsung SMT 7020 DVB-S",
1497 .tuner_type = TUNER_ABSENT, 1497 .tuner_type = UNSET,
1498 .radio_type = UNSET, 1498 .radio_type = UNSET,
1499 .tuner_addr = ADDR_UNSET, 1499 .tuner_addr = ADDR_UNSET,
1500 .radio_addr = ADDR_UNSET, 1500 .radio_addr = ADDR_UNSET,
@@ -1506,7 +1506,7 @@ static const struct cx88_board cx88_boards[] = {
1506 }, 1506 },
1507 [CX88_BOARD_ADSTECH_PTV_390] = { 1507 [CX88_BOARD_ADSTECH_PTV_390] = {
1508 .name = "ADS Tech Instant Video PCI", 1508 .name = "ADS Tech Instant Video PCI",
1509 .tuner_type = TUNER_ABSENT, 1509 .tuner_type = UNSET,
1510 .radio_type = UNSET, 1510 .radio_type = UNSET,
1511 .tuner_addr = ADDR_UNSET, 1511 .tuner_addr = ADDR_UNSET,
1512 .radio_addr = ADDR_UNSET, 1512 .radio_addr = ADDR_UNSET,
@@ -1553,7 +1553,7 @@ static const struct cx88_board cx88_boards[] = {
1553 [CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO] = { 1553 [CX88_BOARD_DVICO_FUSIONHDTV_5_PCI_NANO] = {
1554 .name = "DViCO FusionHDTV 5 PCI nano", 1554 .name = "DViCO FusionHDTV 5 PCI nano",
1555 /* xc3008 tuner, digital only for now */ 1555 /* xc3008 tuner, digital only for now */
1556 .tuner_type = TUNER_ABSENT, 1556 .tuner_type = UNSET,
1557 .radio_type = UNSET, 1557 .radio_type = UNSET,
1558 .tuner_addr = ADDR_UNSET, 1558 .tuner_addr = ADDR_UNSET,
1559 .radio_addr = ADDR_UNSET, 1559 .radio_addr = ADDR_UNSET,
@@ -2069,7 +2069,7 @@ static const struct cx88_board cx88_boards[] = {
2069 }, 2069 },
2070 [CX88_BOARD_TBS_8920] = { 2070 [CX88_BOARD_TBS_8920] = {
2071 .name = "TBS 8920 DVB-S/S2", 2071 .name = "TBS 8920 DVB-S/S2",
2072 .tuner_type = TUNER_ABSENT, 2072 .tuner_type = UNSET,
2073 .radio_type = UNSET, 2073 .radio_type = UNSET,
2074 .tuner_addr = ADDR_UNSET, 2074 .tuner_addr = ADDR_UNSET,
2075 .radio_addr = ADDR_UNSET, 2075 .radio_addr = ADDR_UNSET,
@@ -2304,7 +2304,7 @@ static const struct cx88_board cx88_boards[] = {
2304 }, 2304 },
2305 [CX88_BOARD_TWINHAN_VP1027_DVBS] = { 2305 [CX88_BOARD_TWINHAN_VP1027_DVBS] = {
2306 .name = "Twinhan VP-1027 DVB-S", 2306 .name = "Twinhan VP-1027 DVB-S",
2307 .tuner_type = TUNER_ABSENT, 2307 .tuner_type = UNSET,
2308 .radio_type = UNSET, 2308 .radio_type = UNSET,
2309 .tuner_addr = ADDR_UNSET, 2309 .tuner_addr = ADDR_UNSET,
2310 .radio_addr = ADDR_UNSET, 2310 .radio_addr = ADDR_UNSET,
@@ -2921,33 +2921,33 @@ static const struct {
2921 int fm; 2921 int fm;
2922 const char *name; 2922 const char *name;
2923} gdi_tuner[] = { 2923} gdi_tuner[] = {
2924 [ 0x01 ] = { .id = TUNER_ABSENT, 2924 [ 0x01 ] = { .id = UNSET,
2925 .name = "NTSC_M" }, 2925 .name = "NTSC_M" },
2926 [ 0x02 ] = { .id = TUNER_ABSENT, 2926 [ 0x02 ] = { .id = UNSET,
2927 .name = "PAL_B" }, 2927 .name = "PAL_B" },
2928 [ 0x03 ] = { .id = TUNER_ABSENT, 2928 [ 0x03 ] = { .id = UNSET,
2929 .name = "PAL_I" }, 2929 .name = "PAL_I" },
2930 [ 0x04 ] = { .id = TUNER_ABSENT, 2930 [ 0x04 ] = { .id = UNSET,
2931 .name = "PAL_D" }, 2931 .name = "PAL_D" },
2932 [ 0x05 ] = { .id = TUNER_ABSENT, 2932 [ 0x05 ] = { .id = UNSET,
2933 .name = "SECAM" }, 2933 .name = "SECAM" },
2934 2934
2935 [ 0x10 ] = { .id = TUNER_ABSENT, 2935 [ 0x10 ] = { .id = UNSET,
2936 .fm = 1, 2936 .fm = 1,
2937 .name = "TEMIC_4049" }, 2937 .name = "TEMIC_4049" },
2938 [ 0x11 ] = { .id = TUNER_TEMIC_4136FY5, 2938 [ 0x11 ] = { .id = TUNER_TEMIC_4136FY5,
2939 .name = "TEMIC_4136" }, 2939 .name = "TEMIC_4136" },
2940 [ 0x12 ] = { .id = TUNER_ABSENT, 2940 [ 0x12 ] = { .id = UNSET,
2941 .name = "TEMIC_4146" }, 2941 .name = "TEMIC_4146" },
2942 2942
2943 [ 0x20 ] = { .id = TUNER_PHILIPS_FQ1216ME, 2943 [ 0x20 ] = { .id = TUNER_PHILIPS_FQ1216ME,
2944 .fm = 1, 2944 .fm = 1,
2945 .name = "PHILIPS_FQ1216_MK3" }, 2945 .name = "PHILIPS_FQ1216_MK3" },
2946 [ 0x21 ] = { .id = TUNER_ABSENT, .fm = 1, 2946 [ 0x21 ] = { .id = UNSET, .fm = 1,
2947 .name = "PHILIPS_FQ1236_MK3" }, 2947 .name = "PHILIPS_FQ1236_MK3" },
2948 [ 0x22 ] = { .id = TUNER_ABSENT, 2948 [ 0x22 ] = { .id = UNSET,
2949 .name = "PHILIPS_FI1236_MK3" }, 2949 .name = "PHILIPS_FI1236_MK3" },
2950 [ 0x23 ] = { .id = TUNER_ABSENT, 2950 [ 0x23 ] = { .id = UNSET,
2951 .name = "PHILIPS_FI1216_MK3" }, 2951 .name = "PHILIPS_FI1216_MK3" },
2952}; 2952};
2953 2953
@@ -3564,7 +3564,7 @@ static void cx88_card_setup(struct cx88_core *core)
3564 mode_mask &= ~T_RADIO; 3564 mode_mask &= ~T_RADIO;
3565 } 3565 }
3566 3566
3567 if (core->board.tuner_type != TUNER_ABSENT) { 3567 if (core->board.tuner_type != UNSET) {
3568 tun_setup.mode_mask = mode_mask; 3568 tun_setup.mode_mask = mode_mask;
3569 tun_setup.type = core->board.tuner_type; 3569 tun_setup.type = core->board.tuner_type;
3570 tun_setup.addr = core->board.tuner_addr; 3570 tun_setup.addr = core->board.tuner_addr;
@@ -3777,7 +3777,7 @@ struct cx88_core *cx88_core_create(struct pci_dev *pci, int nr)
3777 cx88_i2c_init(core, pci); 3777 cx88_i2c_init(core, pci);
3778 3778
3779 /* load tuner module, if needed */ 3779 /* load tuner module, if needed */
3780 if (TUNER_ABSENT != core->board.tuner_type) { 3780 if (UNSET != core->board.tuner_type) {
3781 /* Ignore 0x6b and 0x6f on cx88 boards. 3781 /* Ignore 0x6b and 0x6f on cx88 boards.
3782 * FusionHDTV5 RT Gold has an ir receiver at 0x6b 3782 * FusionHDTV5 RT Gold has an ir receiver at 0x6b
3783 * and an RTC at 0x6f which can get corrupted if probed. */ 3783 * and an RTC at 0x6f which can get corrupted if probed. */
diff --git a/drivers/media/pci/cx88/cx88-video.c b/drivers/media/pci/cx88/cx88-video.c
index 64d6a722654c..d8a86cd4e455 100644
--- a/drivers/media/pci/cx88/cx88-video.c
+++ b/drivers/media/pci/cx88/cx88-video.c
@@ -1532,7 +1532,7 @@ static int cx8800_initdev(struct pci_dev *pci_dev,
1532 } 1532 }
1533 1533
1534 /* start tvaudio thread */ 1534 /* start tvaudio thread */
1535 if (core->board.tuner_type != TUNER_ABSENT) { 1535 if (core->board.tuner_type != UNSET) {
1536 core->kthread = kthread_run(cx88_audio_thread, core, "cx88 tvaudio"); 1536 core->kthread = kthread_run(cx88_audio_thread, core, "cx88 tvaudio");
1537 if (IS_ERR(core->kthread)) { 1537 if (IS_ERR(core->kthread)) {
1538 err = PTR_ERR(core->kthread); 1538 err = PTR_ERR(core->kthread);