mirror of
https://github.com/torvalds/linux
synced 2024-10-08 04:12:40 +00:00
media: usb: as102: drop as102_dev NULL check
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 <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
This commit is contained in:
parent
254f3337ce
commit
7cc471112e
|
@ -303,11 +303,9 @@ 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);
|
||||
}
|
||||
}
|
||||
|
||||
static void as102_usb_disconnect(struct usb_interface *intf)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue