diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2009-06-20 11:25:14 +0200 |
---|---|---|
committer | Hans Verkuil <hverkuil@xs4all.nl> | 2009-06-20 11:25:14 +0200 |
commit | 80dc1cf3077100baf270a70d8624f5b682544baf (patch) | |
tree | b0508c03c77248e2fee542bd4a7b389f52e6b53e /linux/drivers/media/radio/radio-si470x.c | |
parent | 5927a4573d2ce0d49736a2fcb4b1e9673deda2fd (diff) | |
download | mediapointer-dvb-s2-80dc1cf3077100baf270a70d8624f5b682544baf.tar.gz mediapointer-dvb-s2-80dc1cf3077100baf270a70d8624f5b682544baf.tar.bz2 |
radio-si470x: conform to the RDS spec.
From: Hans Verkuil <hverkuil@xs4all.nl>
Priority: normal
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux/drivers/media/radio/radio-si470x.c')
-rw-r--r-- | linux/drivers/media/radio/radio-si470x.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/linux/drivers/media/radio/radio-si470x.c b/linux/drivers/media/radio/radio-si470x.c index 101ede1cf..81795da6d 100644 --- a/linux/drivers/media/radio/radio-si470x.c +++ b/linux/drivers/media/radio/radio-si470x.c @@ -1278,7 +1278,7 @@ static int si470x_vidioc_querycap(struct file *file, void *priv, usb_make_path(radio->usbdev, capability->bus_info, sizeof(capability->bus_info)); capability->version = DRIVER_KERNEL_VERSION; capability->capabilities = V4L2_CAP_HW_FREQ_SEEK | - V4L2_CAP_TUNER | V4L2_CAP_RADIO; + V4L2_CAP_TUNER | V4L2_CAP_RADIO | V4L2_CAP_RDS_CAPTURE; return 0; } @@ -1439,7 +1439,8 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv, /* driver constants */ strcpy(tuner->name, "FM"); tuner->type = V4L2_TUNER_RADIO; - tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO; + tuner->capability = V4L2_TUNER_CAP_LOW | V4L2_TUNER_CAP_STEREO | + V4L2_TUNER_CAP_RDS; /* range limits */ switch ((radio->registers[SYSCONFIG2] & SYSCONFIG2_BAND) >> 6) { @@ -1465,6 +1466,10 @@ static int si470x_vidioc_g_tuner(struct file *file, void *priv, tuner->rxsubchans = V4L2_TUNER_SUB_MONO; else tuner->rxsubchans = V4L2_TUNER_SUB_MONO | V4L2_TUNER_SUB_STEREO; + /* If there is a reliable method of detecting an RDS channel, + then this code should check for that before setting this + RDS subchannel. */ + tuner->rxsubchans |= V4L2_TUNER_SUB_RDS; /* mono/stereo selector */ if ((radio->registers[POWERCFG] & POWERCFG_MONO) == 0) |