aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/radio/si470x/radio-si470x-common.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/radio/si470x/radio-si470x-common.c')
-rw-r--r--drivers/media/radio/si470x/radio-si470x-common.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/media/radio/si470x/radio-si470x-common.c b/drivers/media/radio/si470x/radio-si470x-common.c
index 9f9a417caf93..f33315f2c543 100644
--- a/drivers/media/radio/si470x/radio-si470x-common.c
+++ b/drivers/media/radio/si470x/radio-si470x-common.c
@@ -581,8 +581,12 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv,
581 /* driver constants */ 581 /* driver constants */
582 strcpy(tuner->name, "FM"); 582 strcpy(tuner->name, "FM");
583 tuner->type = V4L2_TUNER_RADIO; 583 tuner->type = V4L2_TUNER_RADIO;
584#if defined(CONFIG_USB_SI470X) || defined(CONFIG_USB_SI470X_MODULE)
584 tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO | 585 tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO |
585 V4L2_TUNER_CAP_RDS; 586 V4L2_TUNER_CAP_RDS;
587#else
588 tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO;
589#endif
586 590
587 /* range limits */ 591 /* range limits */
588 switch ((radio->registers[SYSCONFIG2] & SYSCONFIG2_BAND) >> 6) { 592 switch ((radio->registers[SYSCONFIG2] & SYSCONFIG2_BAND) >> 6) {
@@ -608,10 +612,12 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv,
608 tuner->rxsubchans = V4L2_TUNER_SUB_MONO; 612 tuner->rxsubchans = V4L2_TUNER_SUB_MONO;
609 else 613 else
610 tuner->rxsubchans = V4L2_TUNER_SUB_MONO | V4L2_TUNER_SUB_STEREO; 614 tuner->rxsubchans = V4L2_TUNER_SUB_MONO | V4L2_TUNER_SUB_STEREO;
615#if defined(CONFIG_USB_SI470X) || defined(CONFIG_USB_SI470X_MODULE)
611 /* If there is a reliable method of detecting an RDS channel, 616 /* If there is a reliable method of detecting an RDS channel,
612 then this code should check for that before setting this 617 then this code should check for that before setting this
613 RDS subchannel. */ 618 RDS subchannel. */
614 tuner->rxsubchans |= V4L2_TUNER_SUB_RDS; 619 tuner->rxsubchans |= V4L2_TUNER_SUB_RDS;
620#endif
615 621
616 /* mono/stereo selector */ 622 /* mono/stereo selector */
617 if ((radio->registers[POWERCFG] & POWERCFG_MONO) == 0) 623 if ((radio->registers[POWERCFG] & POWERCFG_MONO) == 0)