From: Michael Grzeschik <m.grzeschik@pengutronix.de>
To: linux-usb@vger.kernel.org
Cc: laurent.pinchart@ideasonboard.com,
caleb.connolly@ideasonboard.com, paul.elder@ideasonboard.com,
balbi@kernel.org, kernel@pengutronix.de
Subject: [PATCH v2 3/5] usb: gadget: uvc: set v4l2_dev->dev in f_uvc
Date: Mon, 28 Jun 2021 10:15:58 +0200 [thread overview]
Message-ID: <20210628081600.14525-4-m.grzeschik@pengutronix.de> (raw)
In-Reply-To: <20210628081600.14525-1-m.grzeschik@pengutronix.de>
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>
---
v1 -> v2: Extracted from previous bigger patch
---
drivers/usb/gadget/function/f_uvc.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/gadget/function/f_uvc.c b/drivers/usb/gadget/function/f_uvc.c
index f48a00e497945..9d87c0fb8f92e 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;
--
2.30.2
next prev parent reply other threads:[~2021-06-28 8:16 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-28 8:15 [PATCH v2 0/5] usb: gadget: uvc: improve uvc gadget performance Michael Grzeschik
2021-06-28 8:15 ` [PATCH v2 1/5] usb: dwc3: gadget: set gadgets parent to the right controller Michael Grzeschik
2021-06-28 8:15 ` [PATCH v2 2/5] usb: gadget: uvc: make uvc_num_requests depend on gadget speed Michael Grzeschik
2021-06-28 8:15 ` Michael Grzeschik [this message]
2021-06-28 8:15 ` [PATCH v2 4/5] usb: gadget: uvc: add scatter gather support Michael Grzeschik
2021-06-28 8:16 ` [PATCH v2 5/5] usb: gadget: uvc: decrease the interrupt load to a quarter Michael Grzeschik
2021-06-28 8:25 ` [PATCH v2 0/5] usb: gadget: uvc: improve uvc gadget performance Michael Grzeschik
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210628081600.14525-4-m.grzeschik@pengutronix.de \
--to=m.grzeschik@pengutronix.de \
--cc=balbi@kernel.org \
--cc=caleb.connolly@ideasonboard.com \
--cc=kernel@pengutronix.de \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-usb@vger.kernel.org \
--cc=paul.elder@ideasonboard.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).