This is an automatic generated email to let you know that the following patch 
were queued:

Subject: media: usb: as102: drop as102_dev NULL check
Author:  Hans Verkuil <[email protected]>
Date:    Wed May 24 13:11:45 2023 +0100

Fixes this smatch warning:

drivers/media/usb/as102/as102_usb_drv.c:306 as102_usb_release() warn: can 
'as102_dev' even be NULL?

And indeed, as102_dev can never be NULL, so just drop the NULL check.

Signed-off-by: Hans Verkuil <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>

 drivers/media/usb/as102/as102_usb_drv.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

---

diff --git a/drivers/media/usb/as102/as102_usb_drv.c 
b/drivers/media/usb/as102/as102_usb_drv.c
index 50419e8ae56c..6b380144d6c2 100644
--- a/drivers/media/usb/as102/as102_usb_drv.c
+++ b/drivers/media/usb/as102/as102_usb_drv.c
@@ -303,10 +303,8 @@ static void as102_usb_release(struct kref *kref)
        struct as102_dev_t *as102_dev;
 
        as102_dev = container_of(kref, struct as102_dev_t, kref);
-       if (as102_dev != NULL) {
-               usb_put_dev(as102_dev->bus_adap.usb_dev);
-               kfree(as102_dev);
-       }
+       usb_put_dev(as102_dev->bus_adap.usb_dev);
+       kfree(as102_dev);
 }
 
 static void as102_usb_disconnect(struct usb_interface *intf)

_______________________________________________
linuxtv-commits mailing list
[email protected]
https://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits

Reply via email to