mirror of
https://github.com/torvalds/linux.git
synced 2024-12-22 19:01:37 +00:00
media: rcar-vin: Allow interrupting lock when trying to open the video device
The user should be allowed to break waiting for the lock when opening the video device. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Reviewed-by: Ulrich Hecht <uli+renesas@fpond.eu> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
This commit is contained in:
parent
b2ef816c3d
commit
11492ee7cb
@ -821,7 +821,9 @@ static int rvin_open(struct file *file)
|
||||
struct rvin_dev *vin = video_drvdata(file);
|
||||
int ret;
|
||||
|
||||
mutex_lock(&vin->lock);
|
||||
ret = mutex_lock_interruptible(&vin->lock);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
file->private_data = vin;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user