On Tue Dec 3 21:20:09 2024 +0000, Ricardo Ribalda wrote:
> ctrl->handle will only be different than NULL for controls that have
> mappings. This is because that assignment is only done inside
> uvc_ctrl_set() for mapped controls.
> 
> Cc: [email protected]
> Fixes: e5225c820c05 ("media: uvcvideo: Send a control event when a Control 
> Change interrupt arrives")
> Reviewed-by: Laurent Pinchart <[email protected]>
> Reviewed-by: Hans de Goede <[email protected]>
> Signed-off-by: Ricardo Ribalda <[email protected]>
> Link: 
> https://lore.kernel.org/r/[email protected]
> Signed-off-by: Laurent Pinchart <[email protected]>
> Signed-off-by: Mauro Carvalho Chehab <[email protected]>

Patch committed.

Thanks,
Mauro Carvalho Chehab

 drivers/media/usb/uvc/uvc_ctrl.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

---

diff --git a/drivers/media/usb/uvc/uvc_ctrl.c b/drivers/media/usb/uvc/uvc_ctrl.c
index e0806641a8d0..b05b84887e51 100644
--- a/drivers/media/usb/uvc/uvc_ctrl.c
+++ b/drivers/media/usb/uvc/uvc_ctrl.c
@@ -1640,10 +1640,8 @@ bool uvc_ctrl_status_event_async(struct urb *urb, struct 
uvc_video_chain *chain,
        struct uvc_device *dev = chain->dev;
        struct uvc_ctrl_work *w = &dev->async_ctrl;
 
-       if (list_empty(&ctrl->info.mappings)) {
-               ctrl->handle = NULL;
+       if (list_empty(&ctrl->info.mappings))
                return false;
-       }
 
        w->data = data;
        w->urb = urb;

Reply via email to