diff options
author | Peter Moon <pomoon@gmail.com> | 2011-06-08 14:54:19 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-07-27 16:53:06 -0400 |
commit | de8ae0d516379ef0e0608415a3979ecdd2462c2e (patch) | |
tree | 0e66e253bfbc1002807d52e3d561ad79f606bcfd /drivers/media/video/cx231xx | |
parent | c3f305aab4b2b4334a46a8cc212f4adf05af6798 (diff) |
[media] cx231xx: Add support for Hauppauge WinTV USB2-FM
This patch adds support for the "Hauppauge WinTV USB2-FM" Analog TV Stick.
It includes support for both the PAL and NTSC variants of the device.
Signed-off-by: Peter Moon <pomoon@gmail.com>
Reviewed-by: Devin Heitmueller <dheitmueller@hauppauge.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/cx231xx')
-rw-r--r-- | drivers/media/video/cx231xx/cx231xx-avcore.c | 4 | ||||
-rw-r--r-- | drivers/media/video/cx231xx/cx231xx-cards.c | 74 | ||||
-rw-r--r-- | drivers/media/video/cx231xx/cx231xx-core.c | 4 | ||||
-rw-r--r-- | drivers/media/video/cx231xx/cx231xx.h | 2 |
4 files changed, 84 insertions, 0 deletions
diff --git a/drivers/media/video/cx231xx/cx231xx-avcore.c b/drivers/media/video/cx231xx/cx231xx-avcore.c index 8d7813415760..53ff26e7abf7 100644 --- a/drivers/media/video/cx231xx/cx231xx-avcore.c +++ b/drivers/media/video/cx231xx/cx231xx-avcore.c | |||
@@ -355,6 +355,8 @@ int cx231xx_afe_update_power_control(struct cx231xx *dev, | |||
355 | case CX231XX_BOARD_HAUPPAUGE_EXETER: | 355 | case CX231XX_BOARD_HAUPPAUGE_EXETER: |
356 | case CX231XX_BOARD_HAUPPAUGE_USBLIVE2: | 356 | case CX231XX_BOARD_HAUPPAUGE_USBLIVE2: |
357 | case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: | 357 | case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: |
358 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL: | ||
359 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC: | ||
358 | if (avmode == POLARIS_AVMODE_ANALOGT_TV) { | 360 | if (avmode == POLARIS_AVMODE_ANALOGT_TV) { |
359 | while (afe_power_status != (FLD_PWRDN_TUNING_BIAS | | 361 | while (afe_power_status != (FLD_PWRDN_TUNING_BIAS | |
360 | FLD_PWRDN_ENABLE_PLL)) { | 362 | FLD_PWRDN_ENABLE_PLL)) { |
@@ -1733,6 +1735,8 @@ int cx231xx_dif_set_standard(struct cx231xx *dev, u32 standard) | |||
1733 | break; | 1735 | break; |
1734 | case CX231XX_BOARD_CNXT_RDE_253S: | 1736 | case CX231XX_BOARD_CNXT_RDE_253S: |
1735 | case CX231XX_BOARD_CNXT_RDU_253S: | 1737 | case CX231XX_BOARD_CNXT_RDU_253S: |
1738 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL: | ||
1739 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC: | ||
1736 | func_mode = 0x01; | 1740 | func_mode = 0x01; |
1737 | break; | 1741 | break; |
1738 | default: | 1742 | default: |
diff --git a/drivers/media/video/cx231xx/cx231xx-cards.c b/drivers/media/video/cx231xx/cx231xx-cards.c index 22703815a31f..4b22afee18cf 100644 --- a/drivers/media/video/cx231xx/cx231xx-cards.c +++ b/drivers/media/video/cx231xx/cx231xx-cards.c | |||
@@ -532,6 +532,76 @@ struct cx231xx_board cx231xx_boards[] = { | |||
532 | .gpio = NULL, | 532 | .gpio = NULL, |
533 | } }, | 533 | } }, |
534 | }, | 534 | }, |
535 | [CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL] = { | ||
536 | .name = "Hauppauge WinTV USB2 FM (PAL)", | ||
537 | .tuner_type = TUNER_NXP_TDA18271, | ||
538 | .tuner_addr = 0x60, | ||
539 | .tuner_gpio = RDE250_XCV_TUNER, | ||
540 | .tuner_sif_gpio = 0x05, | ||
541 | .tuner_scl_gpio = 0x1a, | ||
542 | .tuner_sda_gpio = 0x1b, | ||
543 | .decoder = CX231XX_AVDECODER, | ||
544 | .output_mode = OUT_MODE_VIP11, | ||
545 | .ctl_pin_status_mask = 0xFFFFFFC4, | ||
546 | .agc_analog_digital_select_gpio = 0x0c, | ||
547 | .gpio_pin_status_mask = 0x4001000, | ||
548 | .tuner_i2c_master = 1, | ||
549 | .norm = V4L2_STD_PAL, | ||
550 | |||
551 | .input = {{ | ||
552 | .type = CX231XX_VMUX_TELEVISION, | ||
553 | .vmux = CX231XX_VIN_3_1, | ||
554 | .amux = CX231XX_AMUX_VIDEO, | ||
555 | .gpio = NULL, | ||
556 | }, { | ||
557 | .type = CX231XX_VMUX_COMPOSITE1, | ||
558 | .vmux = CX231XX_VIN_2_1, | ||
559 | .amux = CX231XX_AMUX_LINE_IN, | ||
560 | .gpio = NULL, | ||
561 | }, { | ||
562 | .type = CX231XX_VMUX_SVIDEO, | ||
563 | .vmux = CX231XX_VIN_1_1 | | ||
564 | (CX231XX_VIN_1_2 << 8) | | ||
565 | CX25840_SVIDEO_ON, | ||
566 | .amux = CX231XX_AMUX_LINE_IN, | ||
567 | .gpio = NULL, | ||
568 | } }, | ||
569 | }, | ||
570 | [CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC] = { | ||
571 | .name = "Hauppauge WinTV USB2 FM (NTSC)", | ||
572 | .tuner_type = TUNER_NXP_TDA18271, | ||
573 | .tuner_addr = 0x60, | ||
574 | .tuner_gpio = RDE250_XCV_TUNER, | ||
575 | .tuner_sif_gpio = 0x05, | ||
576 | .tuner_scl_gpio = 0x1a, | ||
577 | .tuner_sda_gpio = 0x1b, | ||
578 | .decoder = CX231XX_AVDECODER, | ||
579 | .output_mode = OUT_MODE_VIP11, | ||
580 | .ctl_pin_status_mask = 0xFFFFFFC4, | ||
581 | .agc_analog_digital_select_gpio = 0x0c, | ||
582 | .gpio_pin_status_mask = 0x4001000, | ||
583 | .tuner_i2c_master = 1, | ||
584 | .norm = V4L2_STD_NTSC, | ||
585 | |||
586 | .input = {{ | ||
587 | .type = CX231XX_VMUX_TELEVISION, | ||
588 | .vmux = CX231XX_VIN_3_1, | ||
589 | .amux = CX231XX_AMUX_VIDEO, | ||
590 | .gpio = NULL, | ||
591 | }, { | ||
592 | .type = CX231XX_VMUX_COMPOSITE1, | ||
593 | .vmux = CX231XX_VIN_2_1, | ||
594 | .amux = CX231XX_AMUX_LINE_IN, | ||
595 | .gpio = NULL, | ||
596 | }, { | ||
597 | .type = CX231XX_VMUX_SVIDEO, | ||
598 | .vmux = CX231XX_VIN_1_1 | | ||
599 | (CX231XX_VIN_1_2 << 8) | | ||
600 | CX25840_SVIDEO_ON, | ||
601 | .amux = CX231XX_AMUX_LINE_IN, | ||
602 | .gpio = NULL, | ||
603 | } }, | ||
604 | }, | ||
535 | }; | 605 | }; |
536 | const unsigned int cx231xx_bcount = ARRAY_SIZE(cx231xx_boards); | 606 | const unsigned int cx231xx_bcount = ARRAY_SIZE(cx231xx_boards); |
537 | 607 | ||
@@ -553,6 +623,10 @@ struct usb_device_id cx231xx_id_table[] = { | |||
553 | .driver_info = CX231XX_BOARD_CNXT_RDE_250}, | 623 | .driver_info = CX231XX_BOARD_CNXT_RDE_250}, |
554 | {USB_DEVICE(0x0572, 0x58A0), | 624 | {USB_DEVICE(0x0572, 0x58A0), |
555 | .driver_info = CX231XX_BOARD_CNXT_RDU_250}, | 625 | .driver_info = CX231XX_BOARD_CNXT_RDU_250}, |
626 | {USB_DEVICE(0x2040, 0xb110), | ||
627 | .driver_info = CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL}, | ||
628 | {USB_DEVICE(0x2040, 0xb111), | ||
629 | .driver_info = CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC}, | ||
556 | {USB_DEVICE(0x2040, 0xb120), | 630 | {USB_DEVICE(0x2040, 0xb120), |
557 | .driver_info = CX231XX_BOARD_HAUPPAUGE_EXETER}, | 631 | .driver_info = CX231XX_BOARD_HAUPPAUGE_EXETER}, |
558 | {USB_DEVICE(0x2040, 0xb140), | 632 | {USB_DEVICE(0x2040, 0xb140), |
diff --git a/drivers/media/video/cx231xx/cx231xx-core.c b/drivers/media/video/cx231xx/cx231xx-core.c index abe500feb7dd..d4457f9488ee 100644 --- a/drivers/media/video/cx231xx/cx231xx-core.c +++ b/drivers/media/video/cx231xx/cx231xx-core.c | |||
@@ -742,6 +742,8 @@ int cx231xx_set_mode(struct cx231xx *dev, enum cx231xx_mode set_mode) | |||
742 | case CX231XX_BOARD_CNXT_RDU_253S: | 742 | case CX231XX_BOARD_CNXT_RDU_253S: |
743 | case CX231XX_BOARD_HAUPPAUGE_EXETER: | 743 | case CX231XX_BOARD_HAUPPAUGE_EXETER: |
744 | case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: | 744 | case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: |
745 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL: | ||
746 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC: | ||
745 | errCode = cx231xx_set_agc_analog_digital_mux_select(dev, 0); | 747 | errCode = cx231xx_set_agc_analog_digital_mux_select(dev, 0); |
746 | break; | 748 | break; |
747 | default: | 749 | default: |
@@ -1381,6 +1383,8 @@ int cx231xx_dev_init(struct cx231xx *dev) | |||
1381 | case CX231XX_BOARD_CNXT_RDU_253S: | 1383 | case CX231XX_BOARD_CNXT_RDU_253S: |
1382 | case CX231XX_BOARD_HAUPPAUGE_EXETER: | 1384 | case CX231XX_BOARD_HAUPPAUGE_EXETER: |
1383 | case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: | 1385 | case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: |
1386 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL: | ||
1387 | case CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC: | ||
1384 | errCode = cx231xx_set_agc_analog_digital_mux_select(dev, 0); | 1388 | errCode = cx231xx_set_agc_analog_digital_mux_select(dev, 0); |
1385 | break; | 1389 | break; |
1386 | default: | 1390 | default: |
diff --git a/drivers/media/video/cx231xx/cx231xx.h b/drivers/media/video/cx231xx/cx231xx.h index 46dd84067816..b39b85e732e4 100644 --- a/drivers/media/video/cx231xx/cx231xx.h +++ b/drivers/media/video/cx231xx/cx231xx.h | |||
@@ -67,6 +67,8 @@ | |||
67 | #define CX231XX_BOARD_PV_XCAPTURE_USB 11 | 67 | #define CX231XX_BOARD_PV_XCAPTURE_USB 11 |
68 | #define CX231XX_BOARD_KWORLD_UB430_USB_HYBRID 12 | 68 | #define CX231XX_BOARD_KWORLD_UB430_USB_HYBRID 12 |
69 | #define CX231XX_BOARD_ICONBIT_U100 13 | 69 | #define CX231XX_BOARD_ICONBIT_U100 13 |
70 | #define CX231XX_BOARD_HAUPPAUGE_USB2_FM_PAL 14 | ||
71 | #define CX231XX_BOARD_HAUPPAUGE_USB2_FM_NTSC 15 | ||
70 | 72 | ||
71 | /* Limits minimum and default number of buffers */ | 73 | /* Limits minimum and default number of buffers */ |
72 | #define CX231XX_MIN_BUF 4 | 74 | #define CX231XX_MIN_BUF 4 |