Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 77e6d094 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: sensor: Add mutex lock during ois power down operations"

parents e1680840 b325d3b4
Loading
Loading
Loading
Loading
+2 −0
Original line number Original line Diff line number Diff line
@@ -615,11 +615,13 @@ static long msm_ois_subdev_ioctl(struct v4l2_subdev *sd,
			pr_err("o_ctrl->i2c_client.i2c_func_tbl NULL\n");
			pr_err("o_ctrl->i2c_client.i2c_func_tbl NULL\n");
			return -EINVAL;
			return -EINVAL;
		}
		}
		mutex_lock(o_ctrl->ois_mutex);
		rc = msm_ois_power_down(o_ctrl);
		rc = msm_ois_power_down(o_ctrl);
		if (rc < 0) {
		if (rc < 0) {
			pr_err("%s:%d OIS Power down failed\n",
			pr_err("%s:%d OIS Power down failed\n",
				__func__, __LINE__);
				__func__, __LINE__);
		}
		}
		mutex_unlock(o_ctrl->ois_mutex);
		return msm_ois_close(sd, NULL);
		return msm_ois_close(sd, NULL);
	default:
	default:
		return -ENOIOCTLCMD;
		return -ENOIOCTLCMD;