[PATCH] drm/amd/pm: correct the way for retrieving current uclk frequency

Alex Deucher alexander.deucher at amd.com
Thu May 5 20:07:41 UTC 2022


From: Evan Quan <evan.quan at amd.com>

There is some problem with average frequency reading for now. So,
we switch to the target frequency reading.

Signed-off-by: Evan Quan <evan.quan at amd.com>
Reviewed-by: Likun Gao <Likun.Gao at amd.com>
Signed-off-by: Alex Deucher <alexander.deucher at amd.com>
---
 drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c
index 3fd0ab90b566..f01227e5e96e 100644
--- a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c
+++ b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c
@@ -849,7 +849,7 @@ static int smu_v13_0_0_get_current_clk_freq_by_table(struct smu_context *smu,
 		member_type = METRICS_AVERAGE_GFXCLK;
 		break;
 	case PPCLK_UCLK:
-		member_type = METRICS_AVERAGE_UCLK;
+		member_type = METRICS_CURR_UCLK;
 		break;
 	case PPCLK_FCLK:
 		member_type = METRICS_AVERAGE_FCLK;
-- 
2.35.1



More information about the amd-gfx mailing list