diff options
author | Hans Verkuil <hverkuil-cisco@xs4all.nl> | 2019-06-04 07:19:52 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2019-06-05 08:19:12 -0400 |
commit | e83ce3005db16243e1085925251fd0776bb60d09 (patch) | |
tree | 69ae7135fa6c50a7fbdefa3d66aca32933a3921d /drivers/media/radio/radio-keene.c | |
parent | 7e98b7b542a456582ea3029be857cc99a3b19bd5 (diff) | |
download | linux-stable-e83ce3005db16243e1085925251fd0776bb60d09.tar.gz linux-stable-e83ce3005db16243e1085925251fd0776bb60d09.tar.bz2 linux-stable-e83ce3005db16243e1085925251fd0776bb60d09.zip |
media: media/radio: set device_caps in struct video_device
Instead of filling in the struct v4l2_capability device_caps
field, fill in the struct video_device device_caps field.
That way the V4L2 core knows what the capabilities of the
video device are.
But this only really works if all drivers use this, so convert
all radio drivers in this patch.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/radio/radio-keene.c')
-rw-r--r-- | drivers/media/radio/radio-keene.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/radio/radio-keene.c b/drivers/media/radio/radio-keene.c index e9484b013073..40a051fcd761 100644 --- a/drivers/media/radio/radio-keene.c +++ b/drivers/media/radio/radio-keene.c @@ -177,8 +177,6 @@ static int vidioc_querycap(struct file *file, void *priv, strscpy(v->driver, "radio-keene", sizeof(v->driver)); strscpy(v->card, "Keene FM Transmitter", sizeof(v->card)); usb_make_path(radio->usbdev, v->bus_info, sizeof(v->bus_info)); - v->device_caps = V4L2_CAP_RADIO | V4L2_CAP_MODULATOR; - v->capabilities = v->device_caps | V4L2_CAP_DEVICE_CAPS; return 0; } @@ -370,6 +368,7 @@ static int usb_keene_probe(struct usb_interface *intf, radio->vdev.lock = &radio->lock; radio->vdev.release = video_device_release_empty; radio->vdev.vfl_dir = VFL_DIR_TX; + radio->vdev.device_caps = V4L2_CAP_RADIO | V4L2_CAP_MODULATOR; radio->usbdev = interface_to_usbdev(intf); radio->intf = intf; |