mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-26 06:33:19 -04:00
atomisp/imx: Fix locking bug on error path
This was reported by Dan Carpenter. When we error with an IMX 227 we don't release the lock and the sensor would then hang. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
b834010940
commit
9bc30b3a79
1 changed files with 3 additions and 1 deletions
|
|
@ -454,8 +454,10 @@ static int imx_set_exposure_gain(struct v4l2_subdev *sd, u16 coarse_itg,
|
|||
|
||||
if (dev->sensor_id == IMX227_ID) {
|
||||
ret = imx_write_reg_array(client, imx_param_hold);
|
||||
if (ret)
|
||||
if (ret) {
|
||||
mutex_unlock(&dev->input_lock);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
/* For imx175, setting gain must be delayed by one */
|
||||
|
|
|
|||
Loading…
Reference in a new issue