drm/amdgpu/powerplay: fix mclk switch limit on polaris
authorAlex Deucher <alexander.deucher@amd.com>
Fri, 30 Nov 2018 00:20:28 +0000 (19:20 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 5 Dec 2018 22:49:49 +0000 (17:49 -0500)
Update switch limit on newer polaris variants.  This may fix
flickering with high refresh rates with mclk switching enabled.

Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c

index 66e3d01..6bfbfd3 100644 (file)
@@ -2859,7 +2859,10 @@ static int smu7_vblank_too_short(struct pp_hwmgr *hwmgr,
        case CHIP_POLARIS10:
        case CHIP_POLARIS11:
        case CHIP_POLARIS12:
-               switch_limit_us = data->is_memory_gddr5 ? 190 : 150;
+               if (hwmgr->is_kicker)
+                       switch_limit_us = data->is_memory_gddr5 ? 450 : 150;
+               else
+                       switch_limit_us = data->is_memory_gddr5 ? 190 : 150;
                break;
        case CHIP_VEGAM:
                switch_limit_us = 30;