[COMMON] fimc-is2: Added new function for djag_wb_thres setting
authorSunmi Lee <carrotsm.lee@samsung.com>
Tue, 3 Jul 2018 11:01:59 +0000 (20:01 +0900)
committerSunyoung Kang <sy0816.kang@samsung.com>
Mon, 23 Jul 2018 08:06:10 +0000 (17:06 +0900)
The djab_wb_thres value is defined according to scale_index.

PR JIRA ID: CPR-31

Change-Id: I239a98959eb900bb99c0018df92a59d5d5fca50d
Signed-off-by: Sunmi Lee <carrotsm.lee@samsung.com>
drivers/media/platform/exynos/fimc-is2/hardware/fimc-is-hw-djag.c

index 1047e699f1aac778d2b5f3bd07fcfc4f58674e88..eab7c77a2a96275c15b46533e541a8eee5fd97df 100644 (file)
@@ -103,6 +103,7 @@ int fimc_is_hw_mcsc_update_djag_register(struct fimc_is_hw_ip *hw_ip,
        u32 in_width, in_height;
        u32 out_width = 0, out_height = 0;
        const struct djag_setfile_contents *djag_tuneset;
+       struct djag_wb_thres_cfg *djag_wb = NULL;
        u32 hratio, vratio, min_ratio;
        u32 scale_index = MCSC_DJAG_PRESCALE_INDEX_1, backup_in;
        enum exynos_sensor_position sensor_position;
@@ -198,8 +199,12 @@ int fimc_is_hw_mcsc_update_djag_register(struct fimc_is_hw_ip *hw_ip,
 
 #ifdef MCSC_USE_DEJAG_TUNING_PARAM
        djag_tuneset = &hw_mcsc->cur_setfile[sensor_position]->djag[scale_index];
+#if defined(USE_UVSP_CAC)
+       djag_wb = &hw_mcsc->cur_setfile[sensor_position]->djag_wb[scale_index];
+#endif
 #endif
        fimc_is_scaler_set_djag_tunning_param(hw_ip->regs, djag_tuneset);
+       fimc_is_scaler_set_djag_wb_thres(hw_ip->regs, djag_wb);
 
        fimc_is_scaler_set_djag_enable(hw_ip->regs, 1);