Skip to content

Commit acf7126

Browse files
superm1shuahkh
authored andcommitted
cpupower: Don't fetch maximum latency when EPP is enabled
When EPP has been enabled the hardware will autonomously change frequencies on it's own and thus there is no latency with changing from the kernel. Avoid doing the maximum latency check when EPP is found. This will apply to both amd-pstate and intel-pstate drivers. Link: https://lore.kernel.org/r/20241218191144.3440854-7-superm1@kernel.org Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
1 parent 5f567af commit acf7126

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tools/power/cpupower/utils/cpufreq-info.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,9 @@ static int get_latency(unsigned int cpu, unsigned int human)
445445
{
446446
unsigned long latency = cpufreq_get_transition_latency(cpu);
447447

448+
if (!get_epp(cpu, false))
449+
return -EINVAL;
450+
448451
printf(_(" maximum transition latency: "));
449452
if (!latency || latency == UINT_MAX) {
450453
printf(_(" Cannot determine or is not supported.\n"));

0 commit comments

Comments
 (0)