diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2009-06-20 05:25:14 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-09-12 11:17:33 -0400 |
commit | 43b786677eb15edf7e8a2440878e5fa912bcccc6 (patch) | |
tree | ff38d7b3e561e804a37885bd6f5f8d220e0bcec3 | |
parent | 8e280f24d33dbe7dab719978dfc2f266af76c8af (diff) |
V4L/DVB (12218): radio-si470x: conform to the RDS spec.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r-- | drivers/media/radio/radio-si470x.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/media/radio/radio-si470x.c b/drivers/media/radio/radio-si470x.c index 6710e3f58867..8e6dd84ed208 100644 --- a/drivers/media/radio/radio-si470x.c +++ b/drivers/media/radio/radio-si470x.c | |||
@@ -1254,7 +1254,7 @@ static int si470x_vidioc_querycap(struct file *file, void *priv, | |||
1254 | usb_make_path(radio->usbdev, capability->bus_info, sizeof(capability->bus_info)); | 1254 | usb_make_path(radio->usbdev, capability->bus_info, sizeof(capability->bus_info)); |
1255 | capability->version = DRIVER_KERNEL_VERSION; | 1255 | capability->version = DRIVER_KERNEL_VERSION; |
1256 | capability->capabilities = V4L2_CAP_HW_FREQ_SEEK | | 1256 | capability->capabilities = V4L2_CAP_HW_FREQ_SEEK | |
1257 | V4L2_CAP_TUNER | V4L2_CAP_RADIO; | 1257 | V4L2_CAP_TUNER | V4L2_CAP_RADIO | V4L2_CAP_RDS_CAPTURE; |
1258 | 1258 | ||
1259 | return 0; | 1259 | return 0; |
1260 | } | 1260 | } |
@@ -1413,7 +1413,8 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv, | |||
1413 | /* driver constants */ | 1413 | /* driver constants */ |
1414 | strcpy(tuner->name, "FM"); | 1414 | strcpy(tuner->name, "FM"); |
1415 | tuner->type = V4L2_TUNER_RADIO; | 1415 | tuner->type = V4L2_TUNER_RADIO; |
1416 | tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO; | 1416 | tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO | |
1417 | V4L2_TUNER_CAP_RDS; | ||
1417 | 1418 | ||
1418 | /* range limits */ | 1419 | /* range limits */ |
1419 | switch ((radio->registers[SYSCONFIG2] & SYSCONFIG2_BAND) >> 6) { | 1420 | switch ((radio->registers[SYSCONFIG2] & SYSCONFIG2_BAND) >> 6) { |
@@ -1439,6 +1440,10 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv, | |||
1439 | tuner->rxsubchans = V4L2_TUNER_SUB_MONO; | 1440 | tuner->rxsubchans = V4L2_TUNER_SUB_MONO; |
1440 | else | 1441 | else |
1441 | tuner->rxsubchans = V4L2_TUNER_SUB_MONO | V4L2_TUNER_SUB_STEREO; | 1442 | tuner->rxsubchans = V4L2_TUNER_SUB_MONO | V4L2_TUNER_SUB_STEREO; |
1443 | /* If there is a reliable method of detecting an RDS channel, | ||
1444 | then this code should check for that before setting this | ||
1445 | RDS subchannel. */ | ||
1446 | tuner->rxsubchans |= V4L2_TUNER_SUB_RDS; | ||
1442 | 1447 | ||
1443 | /* mono/stereo selector */ | 1448 | /* mono/stereo selector */ |
1444 | if ((radio->registers[POWERCFG] & POWERCFG_MONO) == 0) | 1449 | if ((radio->registers[POWERCFG] & POWERCFG_MONO) == 0) |