mirror of
https://github.com/torvalds/linux.git
synced 2024-11-19 10:31:48 +00:00
[media] s5p-fimc: Fix locking in subdev set_crop op
When setting TRY crop on the sub-device the mutex was erroneously acquired rather than released on exit path. This bug is present in kernels starting from v3.2. Cc: stable@vger.kernel.org Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
parent
910a5f2e96
commit
e985dbf7d9
@ -1383,7 +1383,7 @@ static int fimc_subdev_set_crop(struct v4l2_subdev *sd,
|
||||
fimc_capture_try_crop(ctx, r, crop->pad);
|
||||
|
||||
if (crop->which == V4L2_SUBDEV_FORMAT_TRY) {
|
||||
mutex_lock(&fimc->lock);
|
||||
mutex_unlock(&fimc->lock);
|
||||
*v4l2_subdev_get_try_crop(fh, crop->pad) = *r;
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user