msm: camera: sensor: Fix delay pass issue in I2C sequential write
When I2C sequential write is applied, first register's delay parameter is used instead of the last one in the sequential queue. CRs-Fixed: 3566036 External Impact: No. Change-Id: I0aa6480d7b577fdb697bc28b61aed428d5cae8fb Signed-off-by: Yulei Yao <quic_yuleiy@quicinc.com> (cherry picked from commit e2ebd508d879607b2dadb1d223c1ad7338989bf2)
This commit is contained in:
@@ -205,9 +205,15 @@ int32_t cam_sensor_handle_delay(
|
|||||||
i2c_list =
|
i2c_list =
|
||||||
list_entry(list_ptr, struct i2c_settings_list, list);
|
list_entry(list_ptr, struct i2c_settings_list, list);
|
||||||
if (generic_op_code ==
|
if (generic_op_code ==
|
||||||
CAMERA_SENSOR_WAIT_OP_HW_UCND)
|
CAMERA_SENSOR_WAIT_OP_HW_UCND) {
|
||||||
i2c_list->i2c_settings.reg_setting[offset - 1].delay =
|
int32_t size = i2c_list->i2c_settings.size;
|
||||||
cmd_uncond_wait->delay;
|
|
||||||
|
if (offset >= size)
|
||||||
|
i2c_list->i2c_settings.reg_setting[offset - size].delay =
|
||||||
|
cmd_uncond_wait->delay;
|
||||||
|
else
|
||||||
|
CAM_WARN(CAM_SENSOR_UTIL, "Setting size is bigger than offset.");
|
||||||
|
}
|
||||||
else
|
else
|
||||||
i2c_list->i2c_settings.delay = cmd_uncond_wait->delay;
|
i2c_list->i2c_settings.delay = cmd_uncond_wait->delay;
|
||||||
(*cmd_buf) +=
|
(*cmd_buf) +=
|
||||||
|
Reference in New Issue
Block a user