Przeglądaj źródła

msm: camera: sensor: Change return code when rejecting packet

When rejecting request that is flushed, return invalid error
desc as opposed to invalid argument.

CRs-Fixed: 3079337
Change-Id: I25ba7c3a9ae62958687a3c2fa69f530397596d0b
Signed-off-by: Karthik Anantha Ram <[email protected]>
Karthik Anantha Ram 3 lat temu
rodzic
commit
d4b9fa4158

+ 1 - 1
drivers/cam_sensor_module/cam_actuator/cam_actuator_core.c

@@ -490,7 +490,7 @@ int32_t cam_actuator_i2c_pkt_parse(struct cam_actuator_ctrl_t *a_ctrl,
 		CAM_DBG(CAM_ACTUATOR,
 			"reject request %lld, last request to flush %lld",
 			csl_packet->header.request_id, a_ctrl->last_flush_req);
-		rc = -EINVAL;
+		rc = -EBADR;
 		goto end;
 	}
 

+ 1 - 1
drivers/cam_sensor_module/cam_flash/cam_flash_core.c

@@ -996,7 +996,7 @@ int cam_flash_i2c_pkt_parser(struct cam_flash_ctrl *fctrl, void *arg)
 		CAM_DBG(CAM_FLASH,
 			"reject request %lld, last request to flush %lld",
 			csl_packet->header.request_id, fctrl->last_flush_req);
-		return -EINVAL;
+		return -EBADR;
 	}
 
 	if (csl_packet->header.request_id > fctrl->last_flush_req)

+ 1 - 1
drivers/cam_sensor_module/cam_sensor/cam_sensor_core.c

@@ -168,7 +168,7 @@ static int32_t cam_sensor_i2c_pkt_parse(struct cam_sensor_ctrl_t *s_ctrl,
 		CAM_ERR(CAM_SENSOR,
 			"reject request %lld, last request to flush %u",
 			csl_packet->header.request_id, s_ctrl->last_flush_req);
-		rc = -EINVAL;
+		rc = -EBADR;
 		goto end;
 	}