diff --git a/drivers/media/platform/msm/camera/cam_isp/cam_isp_context.c b/drivers/media/platform/msm/camera/cam_isp/cam_isp_context.c
index 6470063..0ee368d 100644
--- a/drivers/media/platform/msm/camera/cam_isp/cam_isp_context.c
+++ b/drivers/media/platform/msm/camera/cam_isp/cam_isp_context.c
@@ -691,7 +691,7 @@ static int __cam_isp_ctx_apply_req_in_activated_state(
 	 */
 	ctx_isp = (struct cam_isp_context *) ctx->ctx_priv;
 	if (ctx_isp->active_req_cnt >=  2) {
-		CAM_DBG(CAM_ISP,
+		CAM_ERR_RATE_LIMIT(CAM_ISP,
 			"Reject apply request due to congestion(cnt = %d)",
 			ctx_isp->active_req_cnt);
 		rc = -EFAULT;
@@ -706,6 +706,9 @@ static int __cam_isp_ctx_apply_req_in_activated_state(
 	 * we are in the middle of the error handling. Need to reject this apply
 	 */
 	if (req->request_id != apply->request_id) {
+		CAM_ERR_RATE_LIMIT(CAM_ISP,
+			"Invalid Request Id asking %llu existing %llu",
+			apply->request_id, req->request_id);
 		rc = -EFAULT;
 		goto end;
 	}
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/cam_ife_hw_mgr.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/cam_ife_hw_mgr.c
index 27b9f4a..d0b0751 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/cam_ife_hw_mgr.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/cam_ife_hw_mgr.c
@@ -69,11 +69,11 @@ static int cam_ife_mgr_get_hw_caps(void *hw_mgr_priv,
 	return rc;
 }
 
-static int cam_ife_hw_mgr_is_rdi_res(uint32_t format)
+static int cam_ife_hw_mgr_is_rdi_res(uint32_t res_id)
 {
 	int rc = 0;
 
-	switch (format) {
+	switch (res_id) {
 	case CAM_ISP_IFE_OUT_RES_RDI_0:
 	case CAM_ISP_IFE_OUT_RES_RDI_1:
 	case CAM_ISP_IFE_OUT_RES_RDI_2:
@@ -379,11 +379,12 @@ static void cam_ife_mgr_add_base_info(
 	uint32_t    i;
 
 	if (!ctx->num_base) {
-		CAM_DBG(CAM_ISP, "Add split id = %d for base idx = %d",
-			split_id, base_idx);
 		ctx->base[0].split_id = split_id;
 		ctx->base[0].idx      = base_idx;
 		ctx->num_base++;
+		CAM_DBG(CAM_ISP,
+			"Add split id = %d for base idx = %d num_base=%d",
+			split_id, base_idx, ctx->num_base);
 	} else {
 		/*Check if base index is alreay exist in the list */
 		for (i = 0; i < CAM_IFE_HW_NUM_MAX; i++) {
@@ -398,11 +399,12 @@ static void cam_ife_mgr_add_base_info(
 		}
 
 		if (i == CAM_IFE_HW_NUM_MAX) {
-			CAM_DBG(CAM_ISP, "Add split id = %d for base idx = %d",
-				 split_id, base_idx);
 			ctx->base[ctx->num_base].split_id = split_id;
 			ctx->base[ctx->num_base].idx      = base_idx;
 			ctx->num_base++;
+			CAM_DBG(CAM_ISP,
+				"Add split_id=%d for base idx=%d num_base=%d",
+				 split_id, base_idx, ctx->num_base);
 		}
 	}
 }
@@ -427,15 +429,12 @@ static int cam_ife_mgr_process_base_info(
 		for (i = 0; i < CAM_ISP_HW_SPLIT_MAX; i++) {
 			if (!hw_mgr_res->hw_res[i])
 				continue;
-			res = hw_mgr_res->hw_res[i];
-			if (res->res_id == CAM_ISP_HW_VFE_IN_CAMIF)
-				cam_ife_mgr_add_base_info(ctx, i,
-					res->hw_intf->hw_idx);
 
-			else
-				cam_ife_mgr_add_base_info(ctx,
-						CAM_ISP_HW_SPLIT_MAX,
-						res->hw_intf->hw_idx);
+			res = hw_mgr_res->hw_res[i];
+			cam_ife_mgr_add_base_info(ctx, i,
+					res->hw_intf->hw_idx);
+			CAM_DBG(CAM_ISP, "add base info for hw %d",
+				res->hw_intf->hw_idx);
 		}
 	}
 	CAM_DBG(CAM_ISP, "ctx base num = %d", ctx->num_base);
@@ -676,7 +675,6 @@ static int cam_ife_hw_mgr_acquire_res_ife_src(
 
 		vfe_acquire.rsrc_type = CAM_ISP_RESOURCE_VFE_IN;
 		vfe_acquire.tasklet = ife_ctx->common.tasklet_info;
-		vfe_acquire.rsrc_type = CAM_ISP_RESOURCE_VFE_IN;
 		vfe_acquire.vfe_in.cdm_ops = ife_ctx->cdm_ops;
 
 		switch (csid_res->res_id) {
@@ -787,6 +785,7 @@ static int cam_ife_hw_mgr_acquire_res_ife_csid_ipp(
 	csid_acquire.res_id = CAM_IFE_PIX_PATH_RES_IPP;
 	csid_acquire.cid = cid_res_id;
 	csid_acquire.in_port = in_port;
+	csid_acquire.out_port = in_port->data;
 
 	if (in_port->usage_type)
 		csid_acquire.sync_mode = CAM_ISP_HW_SYNC_MASTER;
@@ -1288,8 +1287,10 @@ static int cam_ife_mgr_acquire_hw(void *hw_mgr_priv,
 	}
 
 	/* Check whether context has only RDI resource */
-	if (!num_pix_port)
+	if (!num_pix_port) {
 		ife_ctx->is_rdi_only_context = 1;
+		CAM_DBG(CAM_ISP, "RDI only context");
+	}
 
 	/* Process base info */
 	rc = cam_ife_mgr_process_base_info(ife_ctx);
@@ -1342,7 +1343,8 @@ static int cam_ife_mgr_config_hw(void *hw_mgr_priv,
 		return -EPERM;
 	}
 
-	CAM_DBG(CAM_ISP, "Enter ctx id:%d", ctx->ctx_index);
+	CAM_DBG(CAM_ISP, "Enter ctx id:%d num_hw_upd_entries %d",
+		ctx->ctx_index, cfg->num_hw_update_entries);
 
 	if (cfg->num_hw_update_entries > 0) {
 		cdm_cmd = ctx->cdm_cmd;
@@ -1359,6 +1361,7 @@ static int cam_ife_mgr_config_hw(void *hw_mgr_priv,
 			cdm_cmd->cmd[i].len = cmd->len;
 		}
 
+		CAM_DBG(CAM_ISP, "Submit to CDM");
 		rc = cam_cdm_submit_bls(ctx->cdm_handle, cdm_cmd);
 		if (rc)
 			CAM_ERR(CAM_ISP, "Failed to apply the configs");
@@ -1914,7 +1917,6 @@ static int cam_ife_mgr_prepare_hw_update(void *hw_mgr_priv,
 	if (rc)
 		return rc;
 
-	CAM_DBG(CAM_ISP, "enter");
 	/* Pre parse the packet*/
 	rc = cam_packet_util_get_kmd_buffer(prepare->packet, &kmd_buf);
 	if (rc)
@@ -2011,14 +2013,22 @@ static int cam_ife_mgr_prepare_hw_update(void *hw_mgr_priv,
 		/* Add change base */
 		rc = cam_isp_add_change_base(prepare, &ctx->res_list_ife_src,
 			ctx->base[i].idx, &kmd_buf);
-		if (rc)
+		if (rc) {
+			CAM_ERR(CAM_ISP,
+				"Failed in change base adding reg_update cmd i=%d, idx=%d, rc=%d",
+				i, ctx->base[i].idx, rc);
 			goto end;
+		}
 
 		/*Add reg update */
 		rc = cam_isp_add_reg_update(prepare, &ctx->res_list_ife_src,
 			ctx->base[i].idx, &kmd_buf);
-		if (rc)
+		if (rc) {
+			CAM_ERR(CAM_ISP,
+				"Add Reg_update cmd Failed i=%d, idx=%d, rc=%d",
+				i, ctx->base[i].idx, rc);
 			goto end;
+		}
 	}
 
 end:
@@ -2804,10 +2814,10 @@ static int cam_ife_hw_mgr_handle_sof(
 						ife_hw_mgr_ctx->common.cb_priv,
 						CAM_ISP_HW_EVENT_SOF,
 						&sof_done_event_data);
+					CAM_DBG(CAM_ISP, "sof_status = %d",
+						sof_status);
 				}
 
-				CAM_DBG(CAM_ISP, "sof_status = %d", sof_status);
-
 				/* this is RDI only context so exit from here */
 				return 0;
 			}
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/hw_utils/cam_isp_packet_parser.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/hw_utils/cam_isp_packet_parser.c
index 3ef96db..698a4c8 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/hw_utils/cam_isp_packet_parser.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/hw_utils/cam_isp_packet_parser.c
@@ -696,6 +696,8 @@ int cam_isp_add_reg_update(
 			if (rc)
 				return rc;
 
+			CAM_DBG(CAM_ISP, "Reg update added for res %d hw_id %d",
+				res->res_id, res->hw_intf->hw_idx);
 			reg_update_size += get_regup.used_bytes;
 		}
 	}
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.c
index a2f773e..9103136 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.c
@@ -32,12 +32,14 @@
 #define CAM_IFE_CSID_TIMEOUT_SLEEP_US                  1000
 #define CAM_IFE_CSID_TIMEOUT_ALL_US                    1000000
 
+#define MEASURE_EN                                     0
+
 static int cam_ife_csid_is_ipp_format_supported(
-				uint32_t decode_fmt)
+	uint32_t in_format)
 {
 	int rc = -EINVAL;
 
-	switch (decode_fmt) {
+	switch (in_format) {
 	case CAM_FORMAT_MIPI_RAW_6:
 	case CAM_FORMAT_MIPI_RAW_8:
 	case CAM_FORMAT_MIPI_RAW_10:
@@ -59,127 +61,221 @@ static int cam_ife_csid_is_ipp_format_supported(
 	return rc;
 }
 
-static int cam_ife_csid_get_format(uint32_t input_fmt,
-	uint32_t *path_fmt)
+static int cam_ife_csid_get_format_rdi(
+	uint32_t in_format, uint32_t out_format,
+	uint32_t *decode_fmt, uint32_t *plain_fmt)
 {
 	int rc = 0;
 
-	switch (input_fmt) {
+	switch (in_format) {
 	case CAM_FORMAT_MIPI_RAW_6:
-		*path_fmt  = 0;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_6:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN8:
+			*decode_fmt = 0x0;
+			*plain_fmt = 0x0;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_MIPI_RAW_8:
-		*path_fmt  = 1;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_8:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN8:
+			*decode_fmt = 0x1;
+			*plain_fmt = 0x0;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_MIPI_RAW_10:
-		*path_fmt  = 2;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_10:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN16_10:
+			*decode_fmt = 0x2;
+			*plain_fmt = 0x1;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_MIPI_RAW_12:
-		*path_fmt  = 3;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_12:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN16_12:
+			*decode_fmt = 0x3;
+			*plain_fmt = 0x1;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_MIPI_RAW_14:
-		*path_fmt  = 4;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_14:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN16_14:
+			*decode_fmt = 0x4;
+			*plain_fmt = 0x1;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_MIPI_RAW_16:
-		*path_fmt  = 5;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_16:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN16_16:
+			*decode_fmt = 0x5;
+			*plain_fmt = 0x1;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_MIPI_RAW_20:
-		*path_fmt  = 6;
+		switch (out_format) {
+		case CAM_FORMAT_MIPI_RAW_20:
+			*decode_fmt = 0xf;
+			break;
+		case CAM_FORMAT_PLAIN32_20:
+			*decode_fmt = 0x6;
+			*plain_fmt = 0x2;
+			break;
+		default:
+			rc = -EINVAL;
+			break;
+		}
 		break;
 	case CAM_FORMAT_DPCM_10_6_10:
-		*path_fmt  = 7;
+		*decode_fmt  = 0x7;
+		*plain_fmt = 0x1;
 		break;
 	case CAM_FORMAT_DPCM_10_8_10:
-		*path_fmt  = 8;
+		*decode_fmt  = 0x8;
+		*plain_fmt = 0x1;
 		break;
 	case CAM_FORMAT_DPCM_12_6_12:
-		*path_fmt  = 9;
+		*decode_fmt  = 0x9;
+		*plain_fmt = 0x1;
 		break;
 	case CAM_FORMAT_DPCM_12_8_12:
-		*path_fmt  = 0xA;
+		*decode_fmt  = 0xA;
+		*plain_fmt = 0x1;
 		break;
 	case CAM_FORMAT_DPCM_14_8_14:
-		*path_fmt  = 0xB;
+		*decode_fmt  = 0xB;
+		*plain_fmt = 0x1;
 		break;
 	case CAM_FORMAT_DPCM_14_10_14:
-		*path_fmt  = 0xC;
+		*decode_fmt  = 0xC;
+		*plain_fmt = 0x1;
 		break;
 	default:
-		CAM_ERR(CAM_ISP, "CSID:%d un supported format",
-			input_fmt);
+		rc = -EINVAL;
+		break;
+	}
+
+	if (rc)
+		CAM_ERR(CAM_ISP, "Unsupported format pair in %d out %d\n",
+			in_format, out_format);
+
+	return rc;
+}
+
+static int cam_ife_csid_get_format_ipp(
+	uint32_t in_format,
+	uint32_t *decode_fmt, uint32_t *plain_fmt)
+{
+	int rc = 0;
+
+	CAM_DBG(CAM_ISP, "input format:%d",
+		 in_format);
+
+	switch (in_format) {
+	case CAM_FORMAT_MIPI_RAW_6:
+		*decode_fmt  = 0;
+		*plain_fmt = 0;
+		break;
+	case CAM_FORMAT_MIPI_RAW_8:
+		*decode_fmt  = 0x1;
+		*plain_fmt = 0;
+		break;
+	case CAM_FORMAT_MIPI_RAW_10:
+		*decode_fmt  = 0x2;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_MIPI_RAW_12:
+		*decode_fmt  = 0x3;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_MIPI_RAW_14:
+		*decode_fmt  = 0x4;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_MIPI_RAW_16:
+		*decode_fmt  = 0x5;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_MIPI_RAW_20:
+		*decode_fmt  = 0x6;
+		*plain_fmt = 0x2;
+		break;
+	case CAM_FORMAT_DPCM_10_6_10:
+		*decode_fmt  = 0x7;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_DPCM_10_8_10:
+		*decode_fmt  = 0x8;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_DPCM_12_6_12:
+		*decode_fmt  = 0x9;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_DPCM_12_8_12:
+		*decode_fmt  = 0xA;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_DPCM_14_8_14:
+		*decode_fmt  = 0xB;
+		*plain_fmt = 0x1;
+		break;
+	case CAM_FORMAT_DPCM_14_10_14:
+		*decode_fmt  = 0xC;
+		*plain_fmt = 0x1;
+		break;
+	default:
+		CAM_ERR(CAM_ISP, "Unsupported format %d",
+			in_format);
 		rc = -EINVAL;
 	}
 
+	CAM_DBG(CAM_ISP, "decode_fmt:%d plain_fmt:%d",
+		 *decode_fmt, *plain_fmt);
+
 	return rc;
 }
 
-static int cam_ife_csid_get_rdi_format(uint32_t input_fmt,
-	uint32_t output_fmt, uint32_t *path_fmt, uint32_t *plain_fmt)
-{
-	int rc = 0;
-
-	CAM_DBG(CAM_ISP, "input format:%d output format:%d",
-		 input_fmt, output_fmt);
-
-	switch (output_fmt) {
-	case CAM_FORMAT_MIPI_RAW_6:
-	case CAM_FORMAT_MIPI_RAW_8:
-	case CAM_FORMAT_MIPI_RAW_10:
-	case CAM_FORMAT_MIPI_RAW_12:
-	case CAM_FORMAT_MIPI_RAW_14:
-	case CAM_FORMAT_MIPI_RAW_16:
-	case CAM_FORMAT_MIPI_RAW_20:
-	case CAM_FORMAT_DPCM_10_6_10:
-	case CAM_FORMAT_DPCM_10_8_10:
-	case CAM_FORMAT_DPCM_12_6_12:
-	case CAM_FORMAT_DPCM_12_8_12:
-	case CAM_FORMAT_DPCM_14_8_14:
-	case CAM_FORMAT_DPCM_14_10_14:
-		*path_fmt  = 0xF;
-		*plain_fmt = 0;
-		break;
-
-	case CAM_FORMAT_PLAIN8:
-		rc = cam_ife_csid_get_format(input_fmt, path_fmt);
-		if (rc)
-			goto error;
-
-		*plain_fmt = 0;
-		break;
-	case CAM_FORMAT_PLAIN16_8:
-	case CAM_FORMAT_PLAIN16_10:
-	case CAM_FORMAT_PLAIN16_12:
-	case CAM_FORMAT_PLAIN16_14:
-	case CAM_FORMAT_PLAIN16_16:
-		rc = cam_ife_csid_get_format(input_fmt, path_fmt);
-		if (rc)
-			goto error;
-
-		*plain_fmt = 1;
-		break;
-	case CAM_FORMAT_PLAIN32_20:
-		rc = cam_ife_csid_get_format(input_fmt, path_fmt);
-		if (rc)
-			goto error;
-
-		*plain_fmt = 2;
-		break;
-	default:
-		*path_fmt  = 0xF;
-		*plain_fmt = 0;
-		break;
-	}
-
-	CAM_DBG(CAM_ISP, "path format value:%d plain format value:%d",
-		 *path_fmt, *plain_fmt);
-
-	return 0;
-error:
-	return rc;
-
-}
-
-
 static int cam_ife_csid_cid_get(struct cam_ife_csid_hw *csid_hw,
 	struct cam_isp_resource_node **res, int32_t vc, uint32_t dt,
 	uint32_t res_type)
@@ -549,7 +645,7 @@ static int cam_ife_csid_cid_reserve(struct cam_ife_csid_hw *csid_hw,
 				goto end;
 				}
 		} else {
-			if (csid_hw->tpg_cfg.decode_fmt !=
+			if (csid_hw->tpg_cfg.in_format !=
 				cid_reserv->in_port->format     ||
 				csid_hw->tpg_cfg.width !=
 				cid_reserv->in_port->left_width ||
@@ -585,7 +681,7 @@ static int cam_ife_csid_cid_reserve(struct cam_ife_csid_hw *csid_hw,
 				rc = -EINVAL;
 				goto end;
 			}
-			csid_hw->tpg_cfg.decode_fmt =
+			csid_hw->tpg_cfg.in_format =
 				cid_reserv->in_port->format;
 			csid_hw->tpg_cfg.width =
 				cid_reserv->in_port->left_width;
@@ -712,20 +808,9 @@ static int cam_ife_csid_path_reserve(struct cam_ife_csid_hw *csid_hw,
 	res->res_state = CAM_ISP_RESOURCE_STATE_RESERVED;
 	path_data = (struct cam_ife_csid_path_cfg   *)res->res_priv;
 
-	/* store the output format for RDI */
-	switch (reserve->res_id) {
-	case CAM_IFE_PIX_PATH_RES_RDI_0:
-	case CAM_IFE_PIX_PATH_RES_RDI_1:
-	case CAM_IFE_PIX_PATH_RES_RDI_2:
-	case CAM_IFE_PIX_PATH_RES_RDI_3:
-		path_data->output_fmt = reserve->out_port->format;
-		break;
-	default:
-		break;
-	}
-
 	path_data->cid = reserve->cid;
-	path_data->decode_fmt = reserve->in_port->format;
+	path_data->in_format = reserve->in_port->format;
+	path_data->out_format = reserve->out_port->format;
 	path_data->master_idx = reserve->master_idx;
 	path_data->sync_mode = reserve->sync_mode;
 	path_data->height  = reserve->in_port->height;
@@ -746,9 +831,14 @@ static int cam_ife_csid_path_reserve(struct cam_ife_csid_hw *csid_hw,
 		path_data->crop_enable = 1;
 		path_data->start_pixel = reserve->in_port->right_start;
 		path_data->width  = reserve->in_port->right_width;
-	} else
+	} else {
 		path_data->crop_enable = 0;
+		path_data->width  = reserve->in_port->left_width;
+		path_data->start_pixel = reserve->in_port->left_start;
+	}
 
+	CAM_DBG(CAM_ISP, "Res %d width %d height %d\n", reserve->res_id,
+		path_data->width, path_data->height);
 	reserve->node_res = res;
 
 end:
@@ -1027,10 +1117,10 @@ static int cam_ife_csid_config_tpg(struct cam_ife_csid_hw   *csid_hw,
 		csid_reg->tpg_reg->csid_tpg_dt_n_cfg_1_addr);
 
 	/*
-	 * decode_fmt is the same as the input resource format.
+	 * in_format is the same as the input resource format.
 	 * it is one larger than the register spec format.
 	 */
-	val = ((csid_hw->tpg_cfg.decode_fmt - 1) << 16) | 0x8;
+	val = ((csid_hw->tpg_cfg.in_format - 1) << 16) | 0x8;
 	cam_io_w_mb(val, soc_info->reg_map[0].mem_base +
 		csid_reg->tpg_reg->csid_tpg_dt_n_cfg_2_addr);
 
@@ -1160,7 +1250,7 @@ static int cam_ife_csid_init_config_ipp_path(
 	struct cam_ife_csid_path_cfg           *path_data;
 	struct cam_ife_csid_reg_offset         *csid_reg;
 	struct cam_hw_soc_info                 *soc_info;
-	uint32_t path_format = 0, val = 0;
+	uint32_t decode_format = 0, plain_format = 0, val = 0;
 
 	path_data = (struct cam_ife_csid_path_cfg  *) res->res_priv;
 	csid_reg = csid_hw->csid_info->csid_reg;
@@ -1173,8 +1263,9 @@ static int cam_ife_csid_init_config_ipp_path(
 		return -EINVAL;
 	}
 
-	CAM_DBG(CAM_ISP, "Enabled IPP Path.......");
-	rc = cam_ife_csid_get_format(path_data->decode_fmt, &path_format);
+	CAM_DBG(CAM_ISP, "Config IPP Path");
+	rc = cam_ife_csid_get_format_ipp(path_data->in_format,
+		&decode_format, &plain_format);
 	if (rc)
 		return rc;
 
@@ -1185,7 +1276,7 @@ static int cam_ife_csid_init_config_ipp_path(
 	val = (path_data->vc << csid_reg->cmn_reg->vc_shift_val) |
 		(path_data->dt << csid_reg->cmn_reg->dt_shift_val) |
 		(path_data->cid << csid_reg->cmn_reg->dt_id_shift_val) |
-		(path_format << csid_reg->cmn_reg->fmt_shift_val) |
+		(decode_format << csid_reg->cmn_reg->fmt_shift_val) |
 		(path_data->crop_enable & 1 <<
 		csid_reg->cmn_reg->crop_h_en_shift_val) |
 		(path_data->crop_enable & 1 <<
@@ -1330,9 +1421,9 @@ static int cam_ife_csid_enable_ipp_path(
 		return -EINVAL;
 	}
 
-	CAM_DBG(CAM_ISP, "enable IPP path.......");
+	CAM_DBG(CAM_ISP, "Enable IPP path");
 
-	/*Resume at frame boundary */
+	/* Resume at frame boundary */
 	if (path_data->sync_mode == CAM_ISP_HW_SYNC_MASTER) {
 		val = cam_io_r_mb(soc_info->reg_map[0].mem_base +
 			csid_reg->ipp_reg->csid_ipp_ctrl_addr);
@@ -1432,7 +1523,7 @@ static int cam_ife_csid_disable_ipp_path(
 			csid_reg->ipp_reg->csid_ipp_irq_mask_addr);
 	} else {
 		val &= ~(CSID_PATH_INFO_RST_DONE |
-				CSID_PATH_ERROR_FIFO_OVERFLOW);
+			CSID_PATH_ERROR_FIFO_OVERFLOW);
 		cam_io_w_mb(val, soc_info->reg_map[0].mem_base +
 			csid_reg->ipp_reg->csid_ipp_irq_mask_addr);
 	}
@@ -1462,8 +1553,8 @@ static int cam_ife_csid_init_config_rdi_path(
 		return -EINVAL;
 	}
 
-	rc = cam_ife_csid_get_rdi_format(path_data->decode_fmt,
-		path_data->output_fmt, &path_format, &plain_fmt);
+	rc = cam_ife_csid_get_format_rdi(path_data->in_format,
+		path_data->out_format, &path_format, &plain_fmt);
 	if (rc)
 		return rc;
 
@@ -1536,6 +1627,18 @@ static int cam_ife_csid_init_config_rdi_path(
 	val = cam_io_r_mb(soc_info->reg_map[0].mem_base +
 		csid_reg->rdi_reg[id]->csid_rdi_cfg0_addr);
 	val |= (1 << csid_reg->cmn_reg->path_en_shift_val);
+#if MEASURE_EN
+	val |= 0x2;
+	cam_io_w_mb(0x3, soc_info->reg_map[0].mem_base +
+		csid_reg->rdi_reg[id]->csid_rdi_format_measure_cfg0_addr);
+	cam_io_w_mb(path_data->height << 16 | path_data->width,
+		soc_info->reg_map[0].mem_base +
+		csid_reg->rdi_reg[id]->csid_rdi_format_measure_cfg1_addr);
+	CAM_DBG(CAM_ISP, "measure_cfg1 0x%x offset 0x%x\n",
+		path_data->height << 16 | path_data->width,
+		csid_reg->rdi_reg[id]->csid_rdi_format_measure_cfg0_addr);
+
+#endif
 	cam_io_w_mb(val, soc_info->reg_map[0].mem_base +
 		csid_reg->rdi_reg[id]->csid_rdi_cfg0_addr);
 
@@ -1605,7 +1708,11 @@ static int cam_ife_csid_enable_rdi_path(
 			csid_reg->rdi_reg[id]->csid_rdi_ctrl_addr);
 
 	/* Enable the required RDI interrupts */
-	val = CSID_PATH_INFO_RST_DONE | CSID_PATH_ERROR_FIFO_OVERFLOW;
+	val = CSID_PATH_INFO_RST_DONE |
+#if MEASURE_EN
+		CSID_PATH_INFO_INPUT_SOF |
+#endif
+		CSID_PATH_ERROR_FIFO_OVERFLOW;
 	cam_io_w_mb(val, soc_info->reg_map[0].mem_base +
 		csid_reg->rdi_reg[id]->csid_rdi_irq_mask_addr);
 
@@ -2298,6 +2405,9 @@ irqreturn_t cam_ife_csid_irq(int irq_num, void *data)
 	struct cam_ife_csid_reg_offset  *csid_reg;
 	uint32_t i, irq_status_top, irq_status_rx, irq_status_ipp = 0,
 		irq_status_rdi[4];
+#if MEASURE_EN
+	uint32_t val;
+#endif
 
 	csid_hw = (struct cam_ife_csid_hw *)data;
 
@@ -2428,8 +2538,15 @@ irqreturn_t cam_ife_csid_irq(int irq_num, void *data)
 			complete(&csid_hw->csid_rdin_complete[i]);
 		}
 
-		if (irq_status_rdi[i]  & CSID_PATH_INFO_INPUT_SOF)
+		if (irq_status_rdi[i]  & CSID_PATH_INFO_INPUT_SOF) {
 			CAM_DBG(CAM_ISP, "CSID RDI SOF received");
+#if MEASURE_EN
+			val = cam_io_r(soc_info->reg_map[0].mem_base +
+				csid_reg->rdi_reg[i]->
+				csid_rdi_format_measure0_addr);
+			CAM_ERR(CAM_ISP, "measure 0x%x\n", val);
+#endif
+		}
 		if (irq_status_rdi[i]  & CSID_PATH_INFO_INPUT_EOF)
 			CAM_DBG(CAM_ISP, "CSID RDI EOF received");
 
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.h b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.h
index ef585c3..d5f032f 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.h
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.h
@@ -320,14 +320,14 @@ struct cam_ife_csid_csi2_rx_cfg  {
  * @width:            width
  * @height:           height
  * @test_pattern :    pattern
- * @decode_format:    decode format
+ * @in_format:        decode format
  *
  */
 struct cam_ife_csid_tpg_cfg  {
 	uint32_t                        width;
 	uint32_t                        height;
 	uint32_t                        test_pattern;
-	uint32_t                        decode_fmt;
+	uint32_t                        in_format;
 };
 
 /**
@@ -353,8 +353,8 @@ struct cam_ife_csid_cid_data {
  * @vc :            Virtual channel number
  * @dt :            Data type number
  * @cid             cid number, it is same as DT_ID number in HW
- * @decode_fmt:     input decode format
- * @output_fmt:     output resource format, needed for RDI resource
+ * @in_format:      input decode format
+ * @out_format:     output format
  * @crop_enable:    crop is enable or disabled, if enabled
  *                  then remaining parameters are valid.
  * @start_pixel:    start pixel
@@ -373,8 +373,8 @@ struct cam_ife_csid_path_cfg {
 	uint32_t                        vc;
 	uint32_t                        dt;
 	uint32_t                        cid;
-	uint32_t                        decode_fmt;
-	uint32_t                        output_fmt;
+	uint32_t                        in_format;
+	uint32_t                        out_format;
 	bool                            crop_enable;
 	uint32_t                        start_pixel;
 	uint32_t                        width;
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/include/cam_ife_csid_hw_intf.h b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/include/cam_ife_csid_hw_intf.h
index 52b712a..a70707a 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/include/cam_ife_csid_hw_intf.h
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/include/cam_ife_csid_hw_intf.h
@@ -10,8 +10,8 @@
  * GNU General Public License for more details.
  */
 
-#ifndef __CAM_CSID_HW_INTF_H__
-#define __CAM_CSID_HW_INTF_H__
+#ifndef _CAM_CSID_HW_INTF_H_
+#define _CAM_CSID_HW_INTF_H_
 
 #include "cam_isp_hw.h"
 #include "cam_hw_intf.h"
@@ -19,7 +19,6 @@
 /* MAX IFE CSID instance */
 #define CAM_IFE_CSID_HW_NUM_MAX                        4
 
-
 /**
  * enum cam_ife_pix_path_res_id - Specify the csid patch
  */
@@ -43,7 +42,6 @@ enum cam_ife_cid_res_id {
 	CAM_IFE_CSID_CID_MAX,
 };
 
-
 /**
  * struct cam_ife_csid_hw_caps- get the CSID hw capability
  * @no_rdis :       number of rdis supported by CSID HW device
@@ -61,7 +59,6 @@ struct cam_ife_csid_hw_caps {
 	uint32_t      version_incr;
 };
 
-
 /**
  * struct cam_csid_hw_reserve_resource- hw reserve
  * @res_type :  reource type CID or PATH
@@ -89,10 +86,8 @@ struct cam_csid_hw_reserve_resource_args {
 	uint32_t                                  master_idx;
 	uint32_t                                  cid;
 	struct cam_isp_resource_node             *node_res;
-
 };
 
-
 /**
  *  enum cam_ife_csid_halt_cmd - Specify the halt command type
  */
@@ -170,4 +165,4 @@ enum cam_ife_csid_cmd_type {
 int cam_ife_csid_hw_init(struct cam_hw_intf **ife_csid_hw,
 	uint32_t hw_idx);
 
-#endif /* __CAM_CSID_HW_INTF_H__ */
+#endif /* _CAM_CSID_HW_INTF_H_ */
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/cam_vfe_core.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/cam_vfe_core.c
index b7db7b3..89db01d 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/cam_vfe_core.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/cam_vfe_core.c
@@ -350,7 +350,11 @@ int cam_vfe_irq_top_half(uint32_t    evt_id,
 	 *  will block everything.
 	 */
 	if (evt_payload->irq_reg_val[1]) {
-		CAM_ERR(CAM_ISP, "Mask all the interrupts");
+		CAM_ERR(CAM_ISP,
+			"Encountered Error Irq_status1=0x%x. Stopping further IRQ processing from this HW",
+			evt_payload->irq_reg_val[1]);
+		CAM_ERR(CAM_ISP, "Violation status = %x",
+			evt_payload->irq_reg_val[2]);
 		cam_io_w(0, handler_priv->mem_base + 0x60);
 		cam_io_w(0, handler_priv->mem_base + 0x5C);
 
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe170/cam_vfe170.h b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe170/cam_vfe170.h
index da96cac..dea906e 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe170/cam_vfe170.h
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe170/cam_vfe170.h
@@ -49,6 +49,7 @@ static struct cam_vfe_camif_ver2_reg vfe170_camif_reg = {
 	.epoch_irq                = 0x000004A0,
 	.raw_crop_width_cfg       = 0x00000CE4,
 	.raw_crop_height_cfg      = 0x00000CE8,
+	.reg_update_cmd           = 0x000004AC,
 };
 
 static struct cam_vfe_camif_reg_data vfe_170_camif_reg_data = {
@@ -66,7 +67,8 @@ static struct cam_vfe_camif_reg_data vfe_170_camif_reg_data = {
 	.extern_reg_update_mask          = 1,
 	.pixel_pattern_shift             = 0,
 	.pixel_pattern_mask              = 0x7,
-	.epoch_line_cfg                  = 0x140000,
+	.reg_update_cmd_data             = 0x1,
+	.epoch_line_cfg                  = 0x00140014,
 	.sof_irq_mask                    = 0x00000001,
 	.epoch0_irq_mask                 = 0x00000004,
 	.reg_update_irq_mask             = 0x00000010,
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_bus/cam_vfe_bus_ver2.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_bus/cam_vfe_bus_ver2.c
index b1aaafb..1fbc105 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_bus/cam_vfe_bus_ver2.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_bus/cam_vfe_bus_ver2.c
@@ -13,6 +13,7 @@
 #include <linux/ratelimit.h>
 #include <linux/slab.h>
 #include "cam_io_util.h"
+#include "cam_debug_util.h"
 #include "cam_cdm_util.h"
 #include "cam_hw_intf.h"
 #include "cam_ife_hw_mgr.h"
@@ -103,7 +104,6 @@ struct cam_vfe_bus_ver2_wm_resource_data {
 	enum cam_vfe_bus_packer_format pack_fmt;
 
 	uint32_t             burst_len;
-	uint32_t             frame_based;
 
 	uint32_t             en_ubwc;
 	uint32_t             packer_cfg;
@@ -360,7 +360,6 @@ static int cam_vfe_bus_get_num_wm(
 		case CAM_FORMAT_DPCM_14_8_14:
 		case CAM_FORMAT_DPCM_14_10_14:
 		case CAM_FORMAT_PLAIN8:
-		case CAM_FORMAT_PLAIN16_8:
 		case CAM_FORMAT_PLAIN16_10:
 		case CAM_FORMAT_PLAIN16_12:
 		case CAM_FORMAT_PLAIN16_14:
@@ -724,14 +723,72 @@ static int cam_vfe_bus_acquire_wm(
 
 	rsrc_data->width = out_port_info->width;
 	rsrc_data->height = out_port_info->height;
+	CAM_DBG(CAM_ISP, "WM %d width %d height %d", rsrc_data->index,
+		rsrc_data->width, rsrc_data->height);
 
 	if (rsrc_data->index < 3) {
 		/* Write master 0-2 refers to RDI 0/ RDI 1/RDI 2 */
-		rsrc_data->width = CAM_VFE_RDI_BUS_DEFAULT_WIDTH;
-		rsrc_data->height = 0;
-		rsrc_data->stride = CAM_VFE_RDI_BUS_DEFAULT_STRIDE;
-		rsrc_data->pack_fmt = 0x0;
-		rsrc_data->en_cfg = 0x3;
+		switch (rsrc_data->format) {
+		case CAM_FORMAT_MIPI_RAW_6:
+		case CAM_FORMAT_MIPI_RAW_8:
+		case CAM_FORMAT_MIPI_RAW_10:
+		case CAM_FORMAT_MIPI_RAW_12:
+		case CAM_FORMAT_MIPI_RAW_14:
+		case CAM_FORMAT_MIPI_RAW_16:
+		case CAM_FORMAT_MIPI_RAW_20:
+			rsrc_data->width = CAM_VFE_RDI_BUS_DEFAULT_WIDTH;
+			rsrc_data->height = 0;
+			rsrc_data->stride = CAM_VFE_RDI_BUS_DEFAULT_STRIDE;
+			rsrc_data->pack_fmt = 0x0;
+			rsrc_data->en_cfg = 0x3;
+			break;
+		case CAM_FORMAT_PLAIN8:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x1;
+			rsrc_data->width = rsrc_data->width * 2;
+			rsrc_data->stride = rsrc_data->width;
+			break;
+		case CAM_FORMAT_PLAIN16_10:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x2;
+			rsrc_data->width = rsrc_data->width * 2;
+			rsrc_data->stride = rsrc_data->width;
+			break;
+		case CAM_FORMAT_PLAIN16_12:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x3;
+			rsrc_data->width = rsrc_data->width * 2;
+			rsrc_data->stride = rsrc_data->width;
+			break;
+		case CAM_FORMAT_PLAIN16_14:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x4;
+			rsrc_data->width = rsrc_data->width * 2;
+			rsrc_data->stride = rsrc_data->width;
+			break;
+		case CAM_FORMAT_PLAIN16_16:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x5;
+			rsrc_data->width = rsrc_data->width * 2;
+			rsrc_data->stride = rsrc_data->width;
+			break;
+		case CAM_FORMAT_PLAIN32_20:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x9;
+			break;
+		case CAM_FORMAT_PLAIN64:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0xA;
+			break;
+		case CAM_FORMAT_PLAIN128:
+			rsrc_data->en_cfg = 0x1;
+			rsrc_data->pack_fmt = 0x0;
+			break;
+		default:
+			CAM_ERR(CAM_ISP, "Unsupported RDI format %d",
+				rsrc_data->format);
+			return -EINVAL;
+		}
 	} else if (rsrc_data->index < 5 ||
 		rsrc_data->index == 7 || rsrc_data->index == 8) {
 		/* Write master 3, 4 - for Full OUT , 7-8  FD OUT */
@@ -813,9 +870,6 @@ static int cam_vfe_bus_acquire_wm(
 		rsrc_data->height = rsrc_data->height / 2;
 		rsrc_data->en_cfg = 0x1;
 	}
-	if (vfe_out_res_id >= CAM_ISP_IFE_OUT_RES_RDI_0 &&
-		vfe_out_res_id <= CAM_ISP_IFE_OUT_RES_RDI_3)
-		rsrc_data->frame_based = 1;
 
 	*client_done_mask = (1 << wm_idx);
 	*wm_res = wm_res_local;
@@ -837,7 +891,6 @@ static int cam_vfe_bus_release_wm(void   *bus_priv,
 	rsrc_data->format = 0;
 	rsrc_data->pack_fmt = 0;
 	rsrc_data->burst_len = 0;
-	rsrc_data->frame_based = 0;
 	rsrc_data->irq_subsample_period = 0;
 	rsrc_data->irq_subsample_pattern = 0;
 	rsrc_data->framedrop_period = 0;
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.c
index 1d15b5b..f255691 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.c
@@ -14,11 +14,13 @@
 #include <uapi/media/cam_isp.h>
 #include "cam_io_util.h"
 #include "cam_isp_hw_mgr_intf.h"
+#include "cam_isp_hw.h"
 #include "cam_vfe_hw_intf.h"
 #include "cam_vfe_top.h"
 #include "cam_vfe_top_ver2.h"
 #include "cam_vfe_camif_ver2.h"
 #include "cam_debug_util.h"
+#include "cam_cdm_util.h"
 
 struct cam_vfe_mux_camif_data {
 	void __iomem                                *mem_base;
@@ -58,6 +60,55 @@ static int cam_vfe_camif_validate_pix_pattern(uint32_t pattern)
 	return rc;
 }
 
+static int cam_vfe_camif_get_reg_update(
+	struct cam_isp_resource_node  *camif_res,
+	void *cmd_args, uint32_t arg_size)
+{
+	uint32_t                          size = 0;
+	uint32_t                          reg_val_pair[2];
+	struct cam_isp_hw_get_cdm_args   *cdm_args = cmd_args;
+	struct cam_cdm_utils_ops         *cdm_util_ops = NULL;
+	struct cam_vfe_mux_camif_data    *rsrc_data = NULL;
+
+	if (arg_size != sizeof(struct cam_isp_hw_get_cdm_args)) {
+		CAM_ERR(CAM_ISP, "Invalid cmd size");
+		return -EINVAL;
+	}
+
+	if (!cdm_args || !cdm_args->res) {
+		CAM_ERR(CAM_ISP, "Invalid args");
+		return -EINVAL;
+	}
+
+	cdm_util_ops = (struct cam_cdm_utils_ops *)cdm_args->res->cdm_ops;
+
+	if (!cdm_util_ops) {
+		CAM_ERR(CAM_ISP, "Invalid CDM ops");
+		return -EINVAL;
+	}
+
+	size = cdm_util_ops->cdm_required_size_reg_random(1);
+	/* since cdm returns dwords, we need to convert it into bytes */
+	if ((size * 4) > cdm_args->size) {
+		CAM_ERR(CAM_ISP, "buf size:%d is not sufficient, expected: %d",
+			cdm_args->size, size);
+		return -EINVAL;
+	}
+
+	rsrc_data = camif_res->res_priv;
+	reg_val_pair[0] = rsrc_data->camif_reg->reg_update_cmd;
+	reg_val_pair[1] = rsrc_data->reg_data->reg_update_cmd_data;
+	CAM_DBG(CAM_ISP, "CAMIF reg_update_cmd %x offset %x",
+		reg_val_pair[1], reg_val_pair[0]);
+
+	cdm_util_ops->cdm_write_regrandom(cdm_args->cmd_buf_addr,
+		1, reg_val_pair);
+
+	cdm_args->used_bytes = size * 4;
+
+	return 0;
+}
+
 int cam_vfe_camif_ver2_acquire_resource(
 	struct cam_isp_resource_node  *camif_res,
 	void                          *acquire_param)
@@ -117,15 +168,16 @@ static int cam_vfe_camif_resource_start(
 			rsrc_data->camif_reg->pixel_skip_pattern);
 
 	/* epoch config with 20 line */
-	cam_io_w_mb(0x00140014,
+	cam_io_w_mb(rsrc_data->reg_data->epoch_line_cfg,
 		rsrc_data->mem_base + rsrc_data->camif_reg->epoch_irq);
 
 	camif_res->res_state = CAM_ISP_RESOURCE_STATE_STREAMING;
 
 	/* Reg Update */
-	cam_io_w_mb(0x1, rsrc_data->mem_base + 0x4AC);
+	cam_io_w_mb(rsrc_data->reg_data->reg_update_cmd_data,
+		rsrc_data->mem_base + rsrc_data->camif_reg->reg_update_cmd);
 
-	CAM_DBG(CAM_ISP, "Exit");
+	CAM_DBG(CAM_ISP, "Start Camif IFE %d Done", camif_res->hw_intf->hw_idx);
 	return 0;
 }
 
@@ -155,10 +207,28 @@ static int cam_vfe_camif_resource_stop(
 	return rc;
 }
 
-int cam_vfe_camif_process_cmd(void *priv,
+static int cam_vfe_camif_process_cmd(struct cam_isp_resource_node *rsrc_node,
 	uint32_t cmd_type, void *cmd_args, uint32_t arg_size)
 {
-	return -EPERM;
+	int rc = -EINVAL;
+
+	if (!rsrc_node || !cmd_args) {
+		CAM_ERR(CAM_ISP, "Invalid input arguments");
+		return -EINVAL;
+	}
+
+	switch (cmd_type) {
+	case CAM_VFE_HW_CMD_GET_REG_UPDATE:
+		rc = cam_vfe_camif_get_reg_update(rsrc_node, cmd_args,
+			arg_size);
+		break;
+	default:
+		CAM_ERR(CAM_ISP,
+			"unsupported process command:%d", cmd_type);
+		break;
+	}
+
+	return rc;
 }
 
 static int cam_vfe_camif_handle_irq_top_half(uint32_t evt_id,
@@ -247,6 +317,7 @@ int cam_vfe_camif_ver2_init(
 
 	camif_node->start = cam_vfe_camif_resource_start;
 	camif_node->stop  = cam_vfe_camif_resource_stop;
+	camif_node->process_cmd = cam_vfe_camif_process_cmd;
 	camif_node->top_half_handler = cam_vfe_camif_handle_irq_top_half;
 	camif_node->bottom_half_handler = cam_vfe_camif_handle_irq_bottom_half;
 
@@ -260,6 +331,7 @@ int cam_vfe_camif_ver2_deinit(
 
 	camif_node->start = NULL;
 	camif_node->stop  = NULL;
+	camif_node->process_cmd = NULL;
 	camif_node->top_half_handler = NULL;
 	camif_node->bottom_half_handler = NULL;
 
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.h b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.h
index 485389a..847b7d5 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.h
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_camif_ver2.h
@@ -50,6 +50,7 @@ struct cam_vfe_camif_reg_data {
 	uint32_t     pixel_pattern_shift;
 	uint32_t     pixel_pattern_mask;
 
+	uint32_t     reg_update_cmd_data;
 	uint32_t     epoch_line_cfg;
 	uint32_t     sof_irq_mask;
 	uint32_t     epoch0_irq_mask;
@@ -67,9 +68,6 @@ int cam_vfe_camif_ver2_acquire_resource(
 	struct cam_isp_resource_node  *camif_res,
 	void                          *acquire_param);
 
-int cam_vfe_camif_process_cmd(void *priv,
-	uint32_t cmd_type, void *cmd_args, uint32_t arg_size);
-
 int cam_vfe_camif_ver2_init(
 	struct cam_hw_intf            *hw_intf,
 	struct cam_hw_soc_info        *soc_info,
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.c
index df7b0f9..461e3c3 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.c
@@ -13,9 +13,11 @@
 #include <linux/slab.h>
 #include "cam_vfe_rdi.h"
 #include "cam_isp_hw_mgr_intf.h"
+#include "cam_isp_hw.h"
 #include "cam_vfe_hw_intf.h"
 #include "cam_io_util.h"
 #include "cam_debug_util.h"
+#include "cam_cdm_util.h"
 
 struct cam_vfe_mux_rdi_data {
 	void __iomem                                *mem_base;
@@ -27,6 +29,54 @@ struct cam_vfe_mux_rdi_data {
 	enum cam_isp_hw_sync_mode          sync_mode;
 };
 
+static int cam_vfe_rdi_get_reg_update(
+	struct cam_isp_resource_node  *rdi_res,
+	void *cmd_args, uint32_t arg_size)
+{
+	uint32_t                          size = 0;
+	uint32_t                          reg_val_pair[2];
+	struct cam_isp_hw_get_cdm_args   *cdm_args = cmd_args;
+	struct cam_cdm_utils_ops         *cdm_util_ops = NULL;
+	struct cam_vfe_mux_rdi_data      *rsrc_data = NULL;
+
+	if (arg_size != sizeof(struct cam_isp_hw_get_cdm_args)) {
+		CAM_ERR(CAM_ISP, "Error - Invalid cmd size");
+		return -EINVAL;
+	}
+
+	if (!cdm_args || !cdm_args->res) {
+		CAM_ERR(CAM_ISP, "Error - Invalid args");
+		return -EINVAL;
+	}
+
+	cdm_util_ops = (struct cam_cdm_utils_ops *)cdm_args->res->cdm_ops;
+	if (!cdm_util_ops) {
+		CAM_ERR(CAM_ISP, "Error - Invalid CDM ops");
+		return -EINVAL;
+	}
+
+	size = cdm_util_ops->cdm_required_size_reg_random(1);
+	/* since cdm returns dwords, we need to convert it into bytes */
+	if ((size * 4) > cdm_args->size) {
+		CAM_ERR(CAM_ISP,
+			"Error - buf size:%d is not sufficient, expected: %d",
+			cdm_args->size, size * 4);
+		return -EINVAL;
+	}
+
+	rsrc_data = rdi_res->res_priv;
+	reg_val_pair[0] = rsrc_data->rdi_reg->reg_update_cmd;
+	reg_val_pair[1] = rsrc_data->reg_data->reg_update_cmd_data;
+	CAM_DBG(CAM_ISP, "Error - RDI%d reg_update_cmd %x",
+		rdi_res->res_id - CAM_ISP_HW_VFE_IN_RDI0, reg_val_pair[1]);
+
+	cdm_util_ops->cdm_write_regrandom(cdm_args->cmd_buf_addr,
+		1, reg_val_pair);
+	cdm_args->used_bytes = size * 4;
+
+	return 0;
+}
+
 int cam_vfe_rdi_ver2_acquire_resource(
 	struct cam_isp_resource_node  *rdi_res,
 	void                          *acquire_param)
@@ -63,9 +113,11 @@ static int cam_vfe_rdi_resource_start(
 	rdi_res->res_state = CAM_ISP_RESOURCE_STATE_STREAMING;
 
 	/* Reg Update */
-	cam_io_w_mb(0x2, rsrc_data->mem_base + 0x4AC);
+	cam_io_w_mb(rsrc_data->reg_data->reg_update_cmd_data,
+		rsrc_data->mem_base + rsrc_data->rdi_reg->reg_update_cmd);
 
-	CAM_DBG(CAM_ISP, "Exit");
+	CAM_DBG(CAM_ISP, "Start RDI %d",
+		rdi_res->res_id - CAM_ISP_HW_VFE_IN_RDI0);
 
 	return rc;
 }
@@ -95,17 +147,21 @@ static int cam_vfe_rdi_resource_stop(
 	return rc;
 }
 
-int cam_vfe_rdi_process_cmd(void *priv,
+static int cam_vfe_rdi_process_cmd(struct cam_isp_resource_node *rsrc_node,
 	uint32_t cmd_type, void *cmd_args, uint32_t arg_size)
 {
 	int rc = -EINVAL;
 
-	if (!priv || !cmd_args) {
+	if (!rsrc_node || !cmd_args) {
 		CAM_ERR(CAM_ISP, "Error! Invalid input arguments");
 		return -EINVAL;
 	}
 
 	switch (cmd_type) {
+	case CAM_VFE_HW_CMD_GET_REG_UPDATE:
+		rc = cam_vfe_rdi_get_reg_update(rsrc_node, cmd_args,
+			arg_size);
+		break;
 	default:
 		CAM_ERR(CAM_ISP,
 			"unsupported RDI process command:%d", cmd_type);
@@ -211,6 +267,7 @@ int cam_vfe_rdi_ver2_init(
 
 	rdi_node->start = cam_vfe_rdi_resource_start;
 	rdi_node->stop  = cam_vfe_rdi_resource_stop;
+	rdi_node->process_cmd = cam_vfe_rdi_process_cmd;
 	rdi_node->top_half_handler = cam_vfe_rdi_handle_irq_top_half;
 	rdi_node->bottom_half_handler = cam_vfe_rdi_handle_irq_bottom_half;
 
@@ -227,6 +284,7 @@ int cam_vfe_rdi_ver2_deinit(
 
 	rdi_node->start = NULL;
 	rdi_node->stop  = NULL;
+	rdi_node->process_cmd = NULL;
 	rdi_node->top_half_handler = NULL;
 	rdi_node->bottom_half_handler = NULL;
 
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.h b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.h
index 04e4f02..32a67c4 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.h
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_rdi.h
@@ -38,9 +38,6 @@ int cam_vfe_rdi_ver2_acquire_resource(
 	struct cam_isp_resource_node  *rdi_res,
 	void                          *acquire_param);
 
-int cam_vfe_rdi_process_cmd(void *priv,
-	uint32_t cmd_type, void *cmd_args, uint32_t arg_size);
-
 int cam_vfe_rdi_ver2_init(
 	struct cam_hw_intf            *hw_intf,
 	struct cam_hw_soc_info        *soc_info,
diff --git a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_top_ver2.c b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_top_ver2.c
index 1a3eeae..f87953d 100644
--- a/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_top_ver2.c
+++ b/drivers/media/platform/msm/camera/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/vfe_top/cam_vfe_top_ver2.c
@@ -80,53 +80,13 @@ static int cam_vfe_top_mux_get_reg_update(
 	struct cam_vfe_top_ver2_priv *top_priv,
 	void *cmd_args, uint32_t arg_size)
 {
-	uint32_t                          size = 0;
-	uint32_t                          reg_val_pair[2];
 	struct cam_isp_hw_get_cdm_args   *cdm_args = cmd_args;
-	struct cam_cdm_utils_ops         *cdm_util_ops = NULL;
 
-	if (arg_size != sizeof(struct cam_isp_hw_get_cdm_args)) {
-		CAM_ERR(CAM_ISP, "Error! Invalid cmd size");
-		return -EINVAL;
-	}
+	if (cdm_args->res->process_cmd)
+		return cdm_args->res->process_cmd(cdm_args->res,
+			CAM_VFE_HW_CMD_GET_REG_UPDATE, cmd_args, arg_size);
 
-	if (!cdm_args || !cdm_args->res) {
-		CAM_ERR(CAM_ISP, "Error! Invalid args");
-		return -EINVAL;
-	}
-
-	cdm_util_ops = (struct cam_cdm_utils_ops *)cdm_args->res->cdm_ops;
-
-	if (!cdm_util_ops) {
-		CAM_ERR(CAM_ISP, "Error! Invalid CDM ops");
-		return -EINVAL;
-	}
-
-	size = cdm_util_ops->cdm_required_size_reg_random(1);
-	/* since cdm returns dwords, we need to convert it into bytes */
-	if ((size * 4) > cdm_args->size) {
-		CAM_ERR(CAM_ISP, "buf size:%d is not sufficient, expected: %d",
-			cdm_args->size, size);
-		return -EINVAL;
-	}
-
-	reg_val_pair[0] = top_priv->common_data.common_reg->reg_update_cmd;
-
-	if (cdm_args->res->res_id == CAM_ISP_HW_VFE_IN_CAMIF)
-		reg_val_pair[1] = BIT(0);
-	else {
-		uint32_t rdi_num = cdm_args->res->res_id -
-			CAM_ISP_HW_VFE_IN_RDI0;
-		/* RDI reg_update starts at BIT 1, so add 1 */
-		reg_val_pair[1] = BIT(rdi_num + 1);
-	}
-
-	cdm_util_ops->cdm_write_regrandom(cdm_args->cmd_buf_addr,
-		1, reg_val_pair);
-
-	cdm_args->used_bytes = size * 4;
-
-	return 0;
+	return -EINVAL;
 }
 
 int cam_vfe_top_get_hw_caps(void *device_priv,
@@ -257,12 +217,8 @@ int cam_vfe_top_start(void *device_priv,
 	top_priv = (struct cam_vfe_top_ver2_priv   *)device_priv;
 	mux_res = (struct cam_isp_resource_node *)start_args;
 
-	if (mux_res->res_id == CAM_ISP_HW_VFE_IN_CAMIF) {
+	if (mux_res->start) {
 		rc = mux_res->start(mux_res);
-	} else if (mux_res->res_id >= CAM_ISP_HW_VFE_IN_RDI0 &&
-		mux_res->res_id <= CAM_ISP_HW_VFE_IN_RDI3) {
-		mux_res->res_state = CAM_ISP_RESOURCE_STATE_STREAMING;
-		rc = 0;
 	} else {
 		CAM_ERR(CAM_ISP, "Invalid res id:%d", mux_res->res_id);
 		rc = -EINVAL;
