瀏覽代碼

msm: camera: isp: Configure UBWC registers during stream on

In some cases while using scratch buffer UBWC registers are not
configured even after receiving the update blob from Userland.
This results in constraint errors at bus side.
This commit configures the UBWC registers at stream on if the
blob was received for the ports which are UBWC enabled.

Change-Id: Icf9a66808432052c84f52bbf470880fde082cee3
CRs-Fixed: 3108015
Signed-off-by: Gaurav Jindal <[email protected]>
Gaurav Jindal 3 年之前
父節點
當前提交
2e6c254487
共有 1 個文件被更改,包括 9 次插入0 次删除
  1. 9 0
      drivers/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_bus/cam_vfe_bus_ver3.c

+ 9 - 0
drivers/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_bus/cam_vfe_bus_ver3.c

@@ -234,6 +234,9 @@ static int cam_vfe_bus_ver3_process_cmd(
 	struct cam_isp_resource_node *priv,
 	uint32_t cmd_type, void *cmd_args, uint32_t arg_size);
 
+static int cam_vfe_bus_ver3_config_ubwc_regs(
+	struct cam_vfe_bus_ver3_wm_resource_data *wm_data);
+
 static int cam_vfe_bus_ver3_get_evt_payload(
 	struct cam_vfe_bus_ver3_common_data  *common_data,
 	struct cam_vfe_bus_irq_evt_payload  **evt_payload)
@@ -1430,6 +1433,12 @@ static int cam_vfe_bus_ver3_start_wm(struct cam_isp_resource_node *wm_res)
 				rsrc_data->index, rsrc_data->en_ubwc);
 			return -EINVAL;
 		}
+
+		if (rsrc_data->ubwc_updated) {
+			cam_vfe_bus_ver3_config_ubwc_regs(rsrc_data);
+			rsrc_data->ubwc_updated = false;
+		}
+
 		val = cam_io_r_mb(common_data->mem_base + ubwc_regs->mode_cfg);
 		val |= 0x1;
 		if (disable_ubwc_comp) {