drm/amd/smu: use AverageGfxclkFrequency* to replace previous GFX Curr Clock
authorjsg <jsg@openbsd.org>
Wed, 13 Sep 2023 12:42:17 +0000 (12:42 +0000)
committerjsg <jsg@openbsd.org>
Wed, 13 Sep 2023 12:42:17 +0000 (12:42 +0000)
From Jane Jian
d7b1aa3e209841834965541988154c296196a808 in linux-6.1.y/6.1.53
4a37c55b859a69f429bfa7fab4fc43ee470b60ed in mainline linux

sys/dev/pci/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c

index 58f9e1c..b9799dd 100644 (file)
@@ -1307,7 +1307,7 @@ static ssize_t smu_v13_0_0_get_gpu_metrics(struct smu_context *smu,
        gpu_metrics->average_vclk1_frequency = metrics->AverageVclk1Frequency;
        gpu_metrics->average_dclk1_frequency = metrics->AverageDclk1Frequency;
 
-       gpu_metrics->current_gfxclk = metrics->CurrClock[PPCLK_GFXCLK];
+       gpu_metrics->current_gfxclk = gpu_metrics->average_gfxclk_frequency;
        gpu_metrics->current_socclk = metrics->CurrClock[PPCLK_SOCCLK];
        gpu_metrics->current_uclk = metrics->CurrClock[PPCLK_UCLK];
        gpu_metrics->current_vclk0 = metrics->CurrClock[PPCLK_VCLK_0];