mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2025-01-21 20:51:06 +07:00
[media] usbvision: fix locking error
If remove_pending is non-zero, then the v4l2_lock is never unlocked. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
This commit is contained in:
parent
4eeda6faae
commit
e2c84ccb0f
@ -426,13 +426,13 @@ static int usbvision_v4l2_close(struct file *file)
|
||||
usbvision_scratch_free(usbvision);
|
||||
|
||||
usbvision->user--;
|
||||
mutex_unlock(&usbvision->v4l2_lock);
|
||||
|
||||
if (usbvision->remove_pending) {
|
||||
printk(KERN_INFO "%s: Final disconnect\n", __func__);
|
||||
usbvision_release(usbvision);
|
||||
return 0;
|
||||
}
|
||||
mutex_unlock(&usbvision->v4l2_lock);
|
||||
|
||||
PDEBUG(DBG_IO, "success");
|
||||
return v4l2_fh_release(file);
|
||||
|
Loading…
Reference in New Issue
Block a user