diff options
author | Michael Grzeschik <m.grzeschik@pengutronix.de> | 2021-06-28 17:53:09 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-07-27 15:59:18 +0200 |
commit | b9b82d3d0dbc45ee6b4817c7a7275a65152301f5 (patch) | |
tree | fb5a3c0cf4296f5f42711a709778cb820533d169 /drivers/usb/gadget | |
parent | usb: gadget: uvc: make uvc_num_requests depend on gadget speed (diff) | |
download | linux-b9b82d3d0dbc45ee6b4817c7a7275a65152301f5.tar.xz linux-b9b82d3d0dbc45ee6b4817c7a7275a65152301f5.zip |
usb: gadget: uvc: set v4l2_dev->dev in f_uvc
The v4l2_dev has no corresponding device to it. We will
point it to the gadget's dev.
Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Link: https://lore.kernel.org/r/20210628155311.16762-4-m.grzeschik@pengutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r-- | drivers/usb/gadget/function/f_uvc.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/gadget/function/f_uvc.c b/drivers/usb/gadget/function/f_uvc.c index f48a00e49794..9d87c0fb8f92 100644 --- a/drivers/usb/gadget/function/f_uvc.c +++ b/drivers/usb/gadget/function/f_uvc.c @@ -418,6 +418,7 @@ uvc_register_video(struct uvc_device *uvc) /* TODO reference counting. */ uvc->vdev.v4l2_dev = &uvc->v4l2_dev; + uvc->vdev.v4l2_dev->dev = &cdev->gadget->dev; uvc->vdev.fops = &uvc_v4l2_fops; uvc->vdev.ioctl_ops = &uvc_v4l2_ioctl_ops; uvc->vdev.release = video_device_release_empty; |