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

Commit 66834220 authored by Shankar Ravi's avatar Shankar Ravi
Browse files

msm: camera: Check for valid per frame i2c data.



Add check for valid i2c data per frame before
consuming in the flush request for actuator.

Change-Id: Iac18bce96eeb276f8244a033cec6f7f05fac5177
Signed-off-by: default avatarShankar Ravi <rshankar@codeaurora.org>
parent 9276c20f
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -878,6 +878,11 @@ int32_t cam_actuator_flush_request(struct cam_req_mgr_flush_request *flush_req)
		return -EINVAL;
	}

	if (a_ctrl->i2c_data.per_frame == NULL) {
		CAM_ERR(CAM_ACTUATOR, "i2c frame data is NULL");
		return -EINVAL;
	}

	for (i = 0; i < MAX_PER_FRAME_ARRAY; i++) {
		i2c_set = &(a_ctrl->i2c_data.per_frame[i]);