]> www.infradead.org Git - users/willy/xarray.git/commitdiff
drm/amd/display: Fix typo when retrieving dppclk from UEFI config
authorMartin Leung <martin.leung@amd.com>
Mon, 22 Feb 2021 18:46:43 +0000 (13:46 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 24 Mar 2021 03:02:23 +0000 (23:02 -0400)
[why]
In some boot configurations we need to retrieve the currently
UEFI-set dppclk, but there was a typo in the calculation

[how]
Fix typo to make dpp_clk calculate off dpp_clk divider instead of
disp_clk

Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Martin Leung <martin.leung@amd.com>
Reviewed-by: Sung Lee <Sung.Lee@amd.com>
Acked-by: Eryk Brol <eryk.brol@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/clk_mgr/dcn20/dcn20_clk_mgr.c

index ec9dc265cde0c4d2def10eeb8f353074e219bd35..372d53b5a34d4506f616d6cfa50d22ddeccf0098 100644 (file)
@@ -361,7 +361,7 @@ void dcn2_read_clocks_from_hw_dentist(struct clk_mgr *clk_mgr_base)
        REG_GET(DENTIST_DISPCLK_CNTL, DENTIST_DPPCLK_WDIVIDER, &dppclk_wdivider);
 
        disp_divider = dentist_get_divider_from_did(dispclk_wdivider);
-       dpp_divider = dentist_get_divider_from_did(dispclk_wdivider);
+       dpp_divider = dentist_get_divider_from_did(dppclk_wdivider);
 
        if (disp_divider && dpp_divider) {
                /* Calculate the current DFS clock, in kHz.*/