Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1298937 > unrolled thread
| Started by | Thierry Reding <thierry.reding@gmail.com> |
|---|---|
| First post | 2015-12-29 11:40 +0100 |
| Last post | 2015-12-29 13:30 +0100 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH] [media] uvcvideo: Fix build if !MEDIA_CONTROLLER Thierry Reding <thierry.reding@gmail.com> - 2015-12-29 11:40 +0100
Re: [PATCH] [media] uvcvideo: Fix build if !MEDIA_CONTROLLER Javier Martinez Canillas <javier@osg.samsung.com> - 2015-12-29 13:30 +0100
| From | Thierry Reding <thierry.reding@gmail.com> |
|---|---|
| Date | 2015-12-29 11:40 +0100 |
| Subject | [PATCH] [media] uvcvideo: Fix build if !MEDIA_CONTROLLER |
| Message-ID | <qKZR7-7Cm-7@gated-at.bofh.it> |
From: Thierry Reding <treding@nvidia.com>
Accesses to the UVC device's mdev field need to be protected by a
preprocessor conditional to avoid build errors, since the field is only
included if the MEDIA_CONTROLLER option is selected.
Fixes: 1590ad7b5271 ("[media] media-device: split media initialization and registration")
Cc: Javier Martinez Canillas <javier@osg.samsung.com>
Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
---
drivers/media/usb/uvc/uvc_driver.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/media/usb/uvc/uvc_driver.c b/drivers/media/usb/uvc/uvc_driver.c
index 4dfd3eb814e7..fc63f9aae63e 100644
--- a/drivers/media/usb/uvc/uvc_driver.c
+++ b/drivers/media/usb/uvc/uvc_driver.c
@@ -1937,9 +1937,11 @@ static int uvc_probe(struct usb_interface *intf,
if (uvc_register_chains(dev) < 0)
goto error;
+#ifdef CONFIG_MEDIA_CONTROLLER
/* Register the media device node */
if (media_device_register(&dev->mdev) < 0)
goto error;
+#endif
/* Save our data pointer in the interface data. */
usb_set_intfdata(intf, dev);
--
2.5.0
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Javier Martinez Canillas <javier@osg.samsung.com> |
|---|---|
| Date | 2015-12-29 13:30 +0100 |
| Message-ID | <qL1zB-ug-21@gated-at.bofh.it> |
| In reply to | #1298937 |
Hello Thierry,
On 12/29/2015 07:30 AM, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
>
> Accesses to the UVC device's mdev field need to be protected by a
> preprocessor conditional to avoid build errors, since the field is only
> included if the MEDIA_CONTROLLER option is selected.
>
> Fixes: 1590ad7b5271 ("[media] media-device: split media initialization and registration")
> Cc: Javier Martinez Canillas <javier@osg.samsung.com>
> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
> Signed-off-by: Thierry Reding <treding@nvidia.com>
> ---
Thanks for the patch but I've already posted the same fix a couple of
days ago [0]. Since the offending commit still has not landed in
mainline, Mauro squashed the fixes with the original commit and will
refresh his next branch soon.
[0]: https://lkml.org/lkml/2015/12/21/224
Best regards,
--
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web