@@ -168,6 +168,10 @@
#define RKISP1_CIF_RSZ_CTRL_CFG_UPD_AUTO BIT(9)
#define RKISP1_CIF_RSZ_SCALER_FACTOR BIT(16)
+#define RKISP1_CIF_RSZ_CTRL_CROP_ENABLE_IMX BIT(8)
+#define RKISP1_CIF_RSZ_CTRL_CFG_UPD_IMX BIT(9)
+#define RKISP1_CIF_RSZ_CTRL_CFG_UPD_AUTO_IMX BIT(10)
+
/* RSZ_CROP_[XY]_DIR */
#define RKISP1_CIF_RSZ_CROP_XY_DIR(start, end) ((end) << 16 | (start) << 0)
@@ -209,9 +209,15 @@ static void rkisp1_rsz_update_shadow(struct rkisp1_resizer *rsz,
u32 ctrl_cfg = rkisp1_rsz_read(rsz, RKISP1_CIF_RSZ_CTRL);
if (when == RKISP1_SHADOW_REGS_ASYNC)
- ctrl_cfg |= RKISP1_CIF_RSZ_CTRL_CFG_UPD_AUTO;
+ if (rsz->rkisp1->info->isp_ver == IMX8MP_V10)
+ ctrl_cfg |= RKISP1_CIF_RSZ_CTRL_CFG_UPD_AUTO_IMX;
+ else
+ ctrl_cfg |= RKISP1_CIF_RSZ_CTRL_CFG_UPD_AUTO;
else
- ctrl_cfg |= RKISP1_CIF_RSZ_CTRL_CFG_UPD;
+ if (rsz->rkisp1->info->isp_ver == IMX8MP_V10)
+ ctrl_cfg |= RKISP1_CIF_RSZ_CTRL_CFG_UPD_IMX;
+ else
+ ctrl_cfg |= RKISP1_CIF_RSZ_CTRL_CFG_UPD;
rkisp1_rsz_write(rsz, RKISP1_CIF_RSZ_CTRL, ctrl_cfg);
}