[9610] fimc-is2: Modify a scenario for DVFS
authordan huh <dan.huh@samsung.com>
Fri, 20 Jul 2018 02:17:14 +0000 (11:17 +0900)
committerWooyeon Kim <wooy88.kim@samsung.com>
Fri, 27 Jul 2018 00:39:10 +0000 (09:39 +0900)
PR JIRA ID: CPR-89

Change-Id: I5ebb2f68b94272aa9a91710bdd154877c0e46f72
Signed-off-by: dan huh <dan.huh@samsung.com>
drivers/media/platform/exynos/fimc-is2/ischain/fimc-is-v6_10_0/fimc-is-hw-dvfs.c
drivers/media/platform/exynos/fimc-is2/ischain/fimc-is-v6_10_0/fimc-is-hw-dvfs.h

index a3eddeb0e4bac348c9d7217407632c585b0f74f8..272f2c5f81d999faccffc8e5fa2e5c73a6ef73a5 100644 (file)
@@ -26,6 +26,10 @@ DECLARE_DVFS_DT(FIMC_IS_SN_END,
                {"front_vt1_"                      , FIMC_IS_SN_FRONT_VT1},
                {"front_vt2_"                      , FIMC_IS_SN_FRONT_VT2},
                {"front_vt4_"                      , FIMC_IS_SN_FRONT_VT4},
+               {"rear2_preview_fhd_"              , FIMC_IS_SN_REAR2_PREVIEW_FHD},
+               {"rear2_capture_"                  , FIMC_IS_SN_REAR2_CAPTURE},
+               {"rear2_video_fhd_"                , FIMC_IS_SN_REAR2_CAMCORDING_FHD},
+               {"rear2_video_fhd_capture_"        , FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE},
                {"rear_preview_full_"              , FIMC_IS_SN_REAR_PREVIEW_FULL},
                {"rear_preview_fhd_"               , FIMC_IS_SN_REAR_PREVIEW_FHD},
                {"rear_preview_hd_"                , FIMC_IS_SN_REAR_PREVIEW_HD},
@@ -37,12 +41,23 @@ DECLARE_DVFS_DT(FIMC_IS_SN_END,
                {"rear_video_fhd_capture_"         , FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE},
                {"rear_video_hd_capture_"                  , FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE},
                {"rear_video_uhd_capture_"         , FIMC_IS_SN_REAR_CAMCORDING_UHD_CAPTURE},
-               {"pip_preview_"                    , FIMC_IS_SN_PIP_PREVIEW},
-               {"pip_capture_"                    , FIMC_IS_SN_PIP_CAPTURE},
-               {"pip_video_"                      , FIMC_IS_SN_PIP_CAMCORDING},
-               {"pip_video_capture_"              , FIMC_IS_SN_PIP_CAMCORDING_CAPTURE},
+               {"dual_preview_"                        , FIMC_IS_SN_DUAL_PREVIEW},
+               {"dual_capture_"                        , FIMC_IS_SN_DUAL_CAPTURE},
+               {"dual_video_fhd_"                      , FIMC_IS_SN_DUAL_FHD_CAMCORDING},
+               {"dual_video_fhd_capture_"              , FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE},
+               {"dual_video_uhd_"                      , FIMC_IS_SN_DUAL_UHD_CAMCORDING},
+               {"dual_video_uhd_capture_"              , FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE},
+               {"dual_sync_preview_"                   , FIMC_IS_SN_DUAL_SYNC_PREVIEW},
+               {"dual_sync_capture_"                   , FIMC_IS_SN_DUAL_SYNC_CAPTURE},
+               {"dual_sync_preview_whd_"               , FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD},
+               {"dual_sync_whd_capture_"               , FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE},
+               {"dual_sync_video_fhd_"                 , FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING},
+               {"dual_sync_video_fhd_capture_"         , FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE},
+               {"dual_sync_video_uhd_"                 , FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING},
+               {"dual_sync_video_uhd_capture_"         , FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE},
                {"preview_high_speed_fps_"         , FIMC_IS_SN_PREVIEW_HIGH_SPEED_FPS},
                {"video_high_speed_60fps_"         , FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS},
+               {"video_high_speed_120fps_"        , FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS},
                {"video_high_speed_480fps_"        , FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS},
                {"video_high_speed_60fps_capture_" , FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE},
                {"ext_rear_"                 , FIMC_IS_SN_EXT_REAR},
@@ -63,6 +78,11 @@ DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_VT1);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_VT2);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_VT4);
 
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_PREVIEW_FHD);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAMCORDING_FHD);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE);
+
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_FULL);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_FHD);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_HD);
@@ -75,13 +95,24 @@ DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_UHD_CAPTURE);
 
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_PREVIEW);
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAPTURE);
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAMCORDING);
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAMCORDING_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_PREVIEW);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_FHD_CAMCORDING);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_UHD_CAMCORDING);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_PREVIEW);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE);
 
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PREVIEW_HIGH_SPEED_FPS);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS);
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS);
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE);
 
@@ -107,30 +138,26 @@ struct fimc_is_dvfs_scenario static_scenarios[] = {
                .scenario_id            = FIMC_IS_SN_SECURE_FRONT,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_SECURE_FRONT),
                .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_SECURE_FRONT),
-       }, {
-               .scenario_id            = FIMC_IS_SN_PIP_CAMCORDING,
-               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_PIP_CAMCORDING),
-               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAMCORDING),
-       }, {
-               .scenario_id            = FIMC_IS_SN_PIP_PREVIEW,
-               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_PIP_PREVIEW),
-               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_PREVIEW),
        }, {
                .scenario_id            = FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS),
                .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS),
+       }, {
+               .scenario_id            = FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS),
        }, {
                .scenario_id            = FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_CAMCORDING_HD,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_CAMCORDING_HD),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_HD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_HD),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_CAMCORDING_FHD,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_CAMCORDING_FHD),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_FHD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_FHD),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_CAMCORDING_UHD,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_CAMCORDING_UHD),
@@ -138,19 +165,55 @@ struct fimc_is_dvfs_scenario static_scenarios[] = {
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_PREVIEW_FULL,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_PREVIEW_FULL),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_FULL),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_FULL),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_PREVIEW_HD,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_PREVIEW_HD),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_HD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_HD),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_PREVIEW_FHD,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_PREVIEW_FHD),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_FHD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_FHD),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_PREVIEW_UHD,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_PREVIEW_UHD),
                .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_UHD),
+       }, {
+               .scenario_id            = FIMC_IS_SN_REAR2_CAMCORDING_FHD,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR2_CAMCORDING_FHD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAMCORDING_FHD),
+       }, {
+               .scenario_id            = FIMC_IS_SN_REAR2_PREVIEW_FHD,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR2_PREVIEW_FHD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_PREVIEW_FHD),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_PREVIEW,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_PREVIEW),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_PREVIEW),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_FHD_CAMCORDING,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_FHD_CAMCORDING),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_FHD_CAMCORDING),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_UHD_CAMCORDING,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_UHD_CAMCORDING),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_UHD_CAMCORDING),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_PREVIEW,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_PREVIEW),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_PREVIEW),
        }, {
                .scenario_id            = FIMC_IS_SN_FRONT_VT1,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_FRONT_VT1),
@@ -170,7 +233,7 @@ struct fimc_is_dvfs_scenario static_scenarios[] = {
        }, {
                .scenario_id            = FIMC_IS_SN_FRONT_PREVIEW_FULL,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_FRONT_PREVIEW_FULL),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_PREVIEW_FULL),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_PREVIEW_FULL),
        }, {
                .scenario_id            = FIMC_IS_SN_FRONT_PREVIEW,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_FRONT_PREVIEW),
@@ -178,7 +241,7 @@ struct fimc_is_dvfs_scenario static_scenarios[] = {
        }, {
                .scenario_id            = FIMC_IS_SN_FRONT_WIDE_SELFIE,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_FRONT_WIDE_SELFIE),
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_WIDE_SELFIE),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_WIDE_SELFIE),
        }
 };
 
@@ -189,30 +252,55 @@ struct fimc_is_dvfs_scenario static_scenarios[] = {
  */
 static struct fimc_is_dvfs_scenario dynamic_scenarios[] = {
        {
-               .scenario_id            = FIMC_IS_SN_PIP_CAMCORDING_CAPTURE,
-               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_PIP_CAMCORDING_CAPTURE),
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE),
                .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
-               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAMCORDING_CAPTURE),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE),
        }, {
-               .scenario_id            = FIMC_IS_SN_PIP_CAPTURE,
-               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_PIP_CAPTURE),
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_CAPTURE),
                .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
-               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAPTURE),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_DUAL_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_DUAL_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_DUAL_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_CAPTURE),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE),
                .keep_frame_tick        = FIMC_IS_DVFS_CAPTURE_TICK,
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE),
                .keep_frame_tick        = FIMC_IS_DVFS_CAPTURE_TICK,
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE),
        }, {
                .scenario_id            = FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE),
                .keep_frame_tick        = FIMC_IS_DVFS_CAPTURE_TICK,
-               .check_func     = GET_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE),
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE),
        }, {
                .scenario_id            = FIMC_IS_SN_REAR_CAMCORDING_UHD_CAPTURE,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR_CAMCORDING_UHD_CAPTURE),
@@ -228,6 +316,16 @@ static struct fimc_is_dvfs_scenario dynamic_scenarios[] = {
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_FRONT_CAMCORDING_CAPTURE),
                .keep_frame_tick        = FIMC_IS_DVFS_CAPTURE_TICK,
                .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_CAMCORDING_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE),
+       }, {
+               .scenario_id            = FIMC_IS_SN_REAR2_CAPTURE,
+               .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_REAR2_CAPTURE),
+               .keep_frame_tick        = FIMC_IS_DVFS_CAPTURE_TICK,
+               .check_func             = GET_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAPTURE),
        }, {
                .scenario_id            = FIMC_IS_SN_FRONT_CAPTURE,
                .scenario_nm            = DVFS_SN_STR(FIMC_IS_SN_FRONT_CAPTURE),
@@ -314,52 +412,30 @@ DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_SECURE_FRONT)
                return 0;
 }
 
-/* pip camcording */
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAMCORDING)
-{
-       return 0;
-}
-
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAMCORDING_CAPTURE)
-{
-       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
-
-       if (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state) &&
-               (static_ctrl->cur_scenario_id == FIMC_IS_SN_PIP_CAMCORDING))
-               return 1;
-       else
-               return 0;
-}
-
-/* pip preview */
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_PREVIEW)
-{
-       if (stream_cnt > 1)
-               return 1;
-       else
-               return 0;
-}
-
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_PIP_CAPTURE)
+/* 60fps recording */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS)
 {
-       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = (mask == ISS_SUB_SCENARIO_FHD_60FPS);
 
-       if (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state) &&
-               (static_ctrl->cur_scenario_id == FIMC_IS_SN_PIP_PREVIEW))
+       if ((position == SENSOR_POSITION_REAR || position == SENSOR_POSITION_REAR2) &&
+                       (fps >= 60) &&
+                       (fps < 120) && setfile_flag)
                return 1;
        else
                return 0;
 }
 
-/* 60fps recording */
-DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS)
+/* 120fps recording */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS)
 {
        u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
-       bool setfile_flag = (mask == ISS_SUB_SCENARIO_FHD_60FPS);
+       bool setfile_flag = (mask == ISS_SUB_SCENARIO_VIDEO_HIGH_SPEED);
 
        if ((position == SENSOR_POSITION_REAR || position == SENSOR_POSITION_REAR2) &&
-                       (fps >= 60) &&
-                       (fps < 120) && setfile_flag)
+                       (fps > 60) &&
+                       (fps <= 120) &&
+                       setfile_flag)
                return 1;
        else
                return 0;
@@ -493,6 +569,226 @@ DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR_PREVIEW_UHD)
                return 0;
 }
 
+/* dual fhd camcording sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING)
+{
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = ((mask == ISS_SUB_SCENARIO_VIDEO) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_ON) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_AUTO));
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               setfile_flag &&
+               (stream_cnt > 1) &&
+#ifdef BDS_IN_VIDEO
+               (resol <= SIZE_12MP_FHD_BDS) &&
+#endif
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual fhd camcording capture sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING) &&
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual uhd camcording sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING)
+{
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = ((mask == ISS_SUB_SCENARIO_UHD_30FPS) ||
+                       (mask == ISS_SUB_SCENARIO_UHD_30FPS_WDR_ON) ||
+                       (mask == ISS_SUB_SCENARIO_UHD_30FPS_WDR_AUTO));
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               setfile_flag &&
+               (stream_cnt > 1) &&
+#ifdef BDS_IN_VIDEO
+               (resol > SIZE_12MP_FHD_BDS) &&
+#endif
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual uhd capcording capture sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING) &&
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual preview sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_PREVIEW)
+{
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (stream_cnt > 1) && (resol <= SIZE_12MP_FHD_BDS) &&
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual preview capture sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_SYNC_PREVIEW) &&
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual whd preview sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD)
+{
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (stream_cnt > 1) && (resol > SIZE_12MP_FHD_BDS) &&
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual whd preview capture sync */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD) &&
+               (dual_info->mode == FIMC_IS_DUAL_MODE_SYNC))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual fhd camcording */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_FHD_CAMCORDING)
+{
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = ((mask == ISS_SUB_SCENARIO_VIDEO) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_ON) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_AUTO));
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               setfile_flag &&
+#ifdef BDS_IN_VIDEO
+               (resol <= SIZE_12MP_FHD_BDS) &&
+#endif
+               (stream_cnt > 1))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual fhd camcording capture */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_FHD_CAMCORDING))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual uhd camcording */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_UHD_CAMCORDING)
+{
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = ((mask == ISS_SUB_SCENARIO_UHD_30FPS) ||
+                       (mask == ISS_SUB_SCENARIO_UHD_30FPS_WDR_ON) ||
+                       (mask == ISS_SUB_SCENARIO_UHD_30FPS_WDR_AUTO));
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               setfile_flag &&
+#ifdef BDS_IN_VIDEO
+               (resol <= SIZE_12MP_FHD_BDS) &&
+#endif
+               (stream_cnt > 1))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual uhd camcording capture */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_UHD_CAMCORDING))
+               return 1;
+       else
+               return 0;
+}
+
+/* dual preview */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_PREVIEW)
+{
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               stream_cnt > 1)
+               return 1;
+       else
+               return 0;
+}
+
+/* dual preview capture */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_DUAL_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((test_bit(SENSOR_POSITION_REAR, &sensor_map)) &&
+               (test_bit(SENSOR_POSITION_REAR2, &sensor_map)) &&
+               (test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_DUAL_PREVIEW))
+               return 1;
+       else
+               return 0;
+}
+
+
 /* front vt1 */
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_VT1)
 {
@@ -504,6 +800,67 @@ DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_VT1)
                return 0;
 }
 
+/* rear2 preview FHD */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_PREVIEW_FHD)
+{
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = ((mask == ISS_SUB_SCENARIO_VIDEO) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_ON) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_AUTO));
+
+       if ((position == SENSOR_POSITION_REAR2) &&
+                       (fps <= 30) &&
+                       (resol <= SIZE_12MP_FHD_BDS) &&
+                       (!setfile_flag))
+
+               return 1;
+       else
+               return 0;
+}
+
+/* rear2 camcording FHD*/
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAMCORDING_FHD)
+{
+       u32 mask = (device->setfile & FIMC_IS_SETFILE_MASK);
+       bool setfile_flag = ((mask == ISS_SUB_SCENARIO_VIDEO) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_ON) ||
+                       (mask == ISS_SUB_SCENARIO_VIDEO_WDR_AUTO));
+
+       if ((position == SENSOR_POSITION_REAR2) &&
+                       (fps <= 30) &&
+#ifdef BDS_IN_VIDEO
+                       (resol <= SIZE_12MP_FHD_BDS) &&
+#endif
+                       setfile_flag)
+               return 1;
+       else
+               return 0;
+}
+
+/* rear2 capture */
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAPTURE)
+{
+       if ((position == SENSOR_POSITION_REAR2) &&
+               test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state)
+               )
+               return 1;
+       else
+               return 0;
+}
+
+DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE)
+{
+       struct fimc_is_dvfs_scenario_ctrl *static_ctrl = device->resourcemgr->dvfs_ctrl.static_ctrl;
+
+       if ((position == SENSOR_POSITION_REAR2) &&
+               test_bit(FIMC_IS_ISCHAIN_REPROCESSING, &device->state) &&
+               (static_ctrl->cur_scenario_id == FIMC_IS_SN_REAR_CAMCORDING_FHD)
+               )
+               return 1;
+       else
+               return 0;
+}
+
 /* front vt2 */
 DECLARE_DVFS_CHK_FUNC(FIMC_IS_SN_FRONT_VT2)
 {
index c652a1c50238b6cdc03cd0e311ea7529d1b66ce9..c94264c68837b0f8fd804c4b58c26b61f2ace5c0 100644 (file)
@@ -21,6 +21,7 @@
 /* FIMC-IS DVFS SCENARIO enum */
 enum FIMC_IS_SCENARIO_ID {
        FIMC_IS_SN_DEFAULT,
+       FIMC_IS_SN_SECURE_FRONT,
        FIMC_IS_SN_FRONT_PREVIEW,
        FIMC_IS_SN_FRONT_PREVIEW_FULL,
        FIMC_IS_SN_FRONT_CAPTURE,
@@ -30,6 +31,10 @@ enum FIMC_IS_SCENARIO_ID {
        FIMC_IS_SN_FRONT_VT1,
        FIMC_IS_SN_FRONT_VT2,
        FIMC_IS_SN_FRONT_VT4,
+       FIMC_IS_SN_REAR2_PREVIEW_FHD,
+       FIMC_IS_SN_REAR2_CAPTURE,
+       FIMC_IS_SN_REAR2_CAMCORDING_FHD,
+       FIMC_IS_SN_REAR2_CAMCORDING_FHD_CAPTURE,
        FIMC_IS_SN_REAR_PREVIEW_FHD,
        FIMC_IS_SN_REAR_PREVIEW_HD,
        FIMC_IS_SN_REAR_PREVIEW_UHD,
@@ -41,13 +46,27 @@ enum FIMC_IS_SCENARIO_ID {
        FIMC_IS_SN_REAR_CAMCORDING_FHD_CAPTURE,
        FIMC_IS_SN_REAR_CAMCORDING_HD_CAPTURE,
        FIMC_IS_SN_REAR_CAMCORDING_UHD_CAPTURE,
-       FIMC_IS_SN_SECURE_FRONT,
+       FIMC_IS_SN_DUAL_PREVIEW,
+       FIMC_IS_SN_DUAL_CAPTURE,
+       FIMC_IS_SN_DUAL_FHD_CAMCORDING,
+       FIMC_IS_SN_DUAL_FHD_CAMCORDING_CAPTURE,
+       FIMC_IS_SN_DUAL_UHD_CAMCORDING,
+       FIMC_IS_SN_DUAL_UHD_CAMCORDING_CAPTURE,
+       FIMC_IS_SN_DUAL_SYNC_PREVIEW,
+       FIMC_IS_SN_DUAL_SYNC_CAPTURE,
+       FIMC_IS_SN_DUAL_SYNC_PREVIEW_WHD,
+       FIMC_IS_SN_DUAL_SYNC_WHD_CAPTURE,
+       FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING,
+       FIMC_IS_SN_DUAL_SYNC_FHD_CAMCORDING_CAPTURE,
+       FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING,
+       FIMC_IS_SN_DUAL_SYNC_UHD_CAMCORDING_CAPTURE,
        FIMC_IS_SN_PIP_PREVIEW,
        FIMC_IS_SN_PIP_CAPTURE,
        FIMC_IS_SN_PIP_CAMCORDING,
        FIMC_IS_SN_PIP_CAMCORDING_CAPTURE,
        FIMC_IS_SN_PREVIEW_HIGH_SPEED_FPS,
        FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS,
+       FIMC_IS_SN_VIDEO_HIGH_SPEED_120FPS,
        FIMC_IS_SN_VIDEO_HIGH_SPEED_480FPS,
        FIMC_IS_SN_VIDEO_HIGH_SPEED_60FPS_CAPTURE,
        FIMC_IS_SN_EXT_REAR,