]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
drm/amd/display: Convert 10kHz clks from PPLib into kHz
authorRex Zhu <rex.zhu@amd.com>
Tue, 17 Jul 2018 12:18:04 +0000 (20:18 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 20 Jul 2018 19:24:10 +0000 (14:24 -0500)
Except special naming as *_in_khz, The default clock unit in powerplay
is in 10KHz. so need to * 10 as expecting clock frequency in display
is in kHz.

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c

index c69ae78d82b24a338f5a4dab7a0c35c13de9b828..fbe878ae1e8c579cc6e2571e30e95400ba477cad 100644 (file)
@@ -469,8 +469,8 @@ bool dm_pp_get_static_clocks(
                return false;
 
        static_clk_info->max_clocks_state = pp_to_dc_powerlevel_state(pp_clk_info.max_clocks_state);
-       static_clk_info->max_mclk_khz = pp_clk_info.max_memory_clock;
-       static_clk_info->max_sclk_khz = pp_clk_info.max_engine_clock;
+       static_clk_info->max_mclk_khz = pp_clk_info.max_memory_clock * 10;
+       static_clk_info->max_sclk_khz = pp_clk_info.max_engine_clock * 10;
 
        return true;
 }