|
@@ -2096,14 +2096,12 @@ static int cam_sfe_bus_wr_update_wm(void *priv, void *cmd_args,
|
|
|
|
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
update_buf->res->res_priv;
|
|
update_buf->res->res_priv;
|
|
-
|
|
|
|
- cdm_util_ops = sfe_out_data->cdm_util_ops;
|
|
|
|
-
|
|
|
|
- if (!sfe_out_data || !cdm_util_ops) {
|
|
|
|
- CAM_ERR(CAM_SFE, "Failed! Invalid data");
|
|
|
|
|
|
+ if (!sfe_out_data || !sfe_out_data->cdm_util_ops) {
|
|
|
|
+ CAM_ERR(CAM_SFE, "Invalid data");
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ cdm_util_ops = sfe_out_data->cdm_util_ops;
|
|
if (update_buf->wm_update->num_buf != sfe_out_data->num_wm) {
|
|
if (update_buf->wm_update->num_buf != sfe_out_data->num_wm) {
|
|
CAM_ERR(CAM_SFE,
|
|
CAM_ERR(CAM_SFE,
|
|
"Failed! Invalid number buffers:%d required:%d",
|
|
"Failed! Invalid number buffers:%d required:%d",
|
|
@@ -2295,8 +2293,8 @@ static int cam_sfe_bus_wr_config_wm(void *priv, void *cmd_args,
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
update_buf->res->res_priv;
|
|
update_buf->res->res_priv;
|
|
|
|
|
|
- if (!sfe_out_data || !sfe_out_data->cdm_util_ops) {
|
|
|
|
- CAM_ERR(CAM_SFE, "Failed! Invalid data");
|
|
|
|
|
|
+ if (!sfe_out_data) {
|
|
|
|
+ CAM_ERR(CAM_SFE, "Invalid data");
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -2426,12 +2424,12 @@ static int cam_sfe_bus_wr_update_hfr(void *priv, void *cmd_args,
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
update_hfr->res->res_priv;
|
|
update_hfr->res->res_priv;
|
|
|
|
|
|
- cdm_util_ops = sfe_out_data->cdm_util_ops;
|
|
|
|
- if (!sfe_out_data || !cdm_util_ops) {
|
|
|
|
- CAM_ERR(CAM_SFE, "Failed! Invalid data");
|
|
|
|
|
|
+ if (!sfe_out_data || !sfe_out_data->cdm_util_ops) {
|
|
|
|
+ CAM_ERR(CAM_SFE, "Invalid data");
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ cdm_util_ops = sfe_out_data->cdm_util_ops;
|
|
reg_val_pair = &sfe_out_data->common_data->io_buf_update[0];
|
|
reg_val_pair = &sfe_out_data->common_data->io_buf_update[0];
|
|
hfr_cfg = (struct cam_isp_port_hfr_config *)update_hfr->data;
|
|
hfr_cfg = (struct cam_isp_port_hfr_config *)update_hfr->data;
|
|
|
|
|
|
@@ -2648,16 +2646,12 @@ static int cam_sfe_bus_wr_update_bw_limiter(
|
|
|
|
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
sfe_out_data = (struct cam_sfe_bus_wr_out_data *)
|
|
wm_config_update->res->res_priv;
|
|
wm_config_update->res->res_priv;
|
|
-
|
|
|
|
- cdm_util_ops = sfe_out_data->cdm_util_ops;
|
|
|
|
-
|
|
|
|
- if (!sfe_out_data || !cdm_util_ops) {
|
|
|
|
- CAM_ERR(CAM_SFE,
|
|
|
|
- "Failed invalid data out_data: %pK cdm_utils_ops: %pK",
|
|
|
|
- sfe_out_data, cdm_util_ops);
|
|
|
|
|
|
+ if (!sfe_out_data || !sfe_out_data->cdm_util_ops) {
|
|
|
|
+ CAM_ERR(CAM_SFE, "Invalid data");
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ cdm_util_ops = sfe_out_data->cdm_util_ops;
|
|
reg_val_pair = &sfe_out_data->common_data->io_buf_update[0];
|
|
reg_val_pair = &sfe_out_data->common_data->io_buf_update[0];
|
|
for (i = 0, j = 0; i < sfe_out_data->num_wm; i++) {
|
|
for (i = 0, j = 0; i < sfe_out_data->num_wm; i++) {
|
|
if (j >= (MAX_REG_VAL_PAIR_SIZE - (MAX_BUF_UPDATE_REG_NUM * 2))) {
|
|
if (j >= (MAX_REG_VAL_PAIR_SIZE - (MAX_BUF_UPDATE_REG_NUM * 2))) {
|