Commit 9793e1d2 authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Mauro Carvalho Chehab

media: au0828: fix unbalanced lock/unlock in au0828_usb_probe

Call mutex_unlock and free dev on failure.
Reported-by: default avatarJulia Lawall <julia.lawall@lip6.fr>
Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent be90cc8e
...@@ -628,6 +628,8 @@ static int au0828_usb_probe(struct usb_interface *interface, ...@@ -628,6 +628,8 @@ static int au0828_usb_probe(struct usb_interface *interface,
if (retval) { if (retval) {
pr_err("%s() au0282_dev_register failed to register on V4L2\n", pr_err("%s() au0282_dev_register failed to register on V4L2\n",
__func__); __func__);
mutex_unlock(&dev->lock);
kfree(dev);
goto done; goto done;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment