mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-22 10:58:18 +07:00
drm/amd/powerplay: correct current clock level label for Arcturus
For dpm disabled case, it's assumed the only one support clock level is always current clock level. Signed-off-by: Evan Quan <evan.quan@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
0525f29713
commit
59e038d067
@ -628,12 +628,17 @@ static int arcturus_print_clk_levels(struct smu_context *smu,
|
||||
return ret;
|
||||
}
|
||||
|
||||
/*
|
||||
* For DPM disabled case, there will be only one clock level.
|
||||
* And it's safe to assume that is always the current clock.
|
||||
*/
|
||||
for (i = 0; i < clocks.num_levels; i++)
|
||||
size += sprintf(buf + size, "%d: %uMhz %s\n", i,
|
||||
clocks.data[i].clocks_in_khz / 1000,
|
||||
arcturus_freqs_in_same_level(
|
||||
(clocks.num_levels == 1) ? "*" :
|
||||
(arcturus_freqs_in_same_level(
|
||||
clocks.data[i].clocks_in_khz / 1000,
|
||||
now / 100) ? "*" : "");
|
||||
now / 100) ? "*" : ""));
|
||||
break;
|
||||
|
||||
case SMU_MCLK:
|
||||
@ -653,9 +658,10 @@ static int arcturus_print_clk_levels(struct smu_context *smu,
|
||||
for (i = 0; i < clocks.num_levels; i++)
|
||||
size += sprintf(buf + size, "%d: %uMhz %s\n",
|
||||
i, clocks.data[i].clocks_in_khz / 1000,
|
||||
arcturus_freqs_in_same_level(
|
||||
(clocks.num_levels == 1) ? "*" :
|
||||
(arcturus_freqs_in_same_level(
|
||||
clocks.data[i].clocks_in_khz / 1000,
|
||||
now / 100) ? "*" : "");
|
||||
now / 100) ? "*" : ""));
|
||||
break;
|
||||
|
||||
case SMU_SOCCLK:
|
||||
@ -675,9 +681,10 @@ static int arcturus_print_clk_levels(struct smu_context *smu,
|
||||
for (i = 0; i < clocks.num_levels; i++)
|
||||
size += sprintf(buf + size, "%d: %uMhz %s\n",
|
||||
i, clocks.data[i].clocks_in_khz / 1000,
|
||||
arcturus_freqs_in_same_level(
|
||||
(clocks.num_levels == 1) ? "*" :
|
||||
(arcturus_freqs_in_same_level(
|
||||
clocks.data[i].clocks_in_khz / 1000,
|
||||
now / 100) ? "*" : "");
|
||||
now / 100) ? "*" : ""));
|
||||
break;
|
||||
|
||||
case SMU_FCLK:
|
||||
@ -697,9 +704,10 @@ static int arcturus_print_clk_levels(struct smu_context *smu,
|
||||
for (i = 0; i < single_dpm_table->count; i++)
|
||||
size += sprintf(buf + size, "%d: %uMhz %s\n",
|
||||
i, single_dpm_table->dpm_levels[i].value,
|
||||
arcturus_freqs_in_same_level(
|
||||
(clocks.num_levels == 1) ? "*" :
|
||||
(arcturus_freqs_in_same_level(
|
||||
clocks.data[i].clocks_in_khz / 1000,
|
||||
now / 100) ? "*" : "");
|
||||
now / 100) ? "*" : ""));
|
||||
break;
|
||||
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user