cancel
Showing results for 
Search instead for 
Did you mean: 

Server Gurus Discussions

cruz7
Journeyman III

can't set cpu frequency governor with cpupower on AMD EPYC 7702P

I have a server HPE ProLiant system with AMD Epyc CPU, BIOS A43 v1.20, with Linux kernel 4.19.71. Now, I'm trying to set CPU performance governor:

 

# cpupower frequency-set -g performance
    Setting cpu: 0
    Error setting new values. Common errors:
    - Do you have proper administration rights? (super-user?)
    - Is the governor you requested available and modprobed?
    - Trying to set an invalid policy?
    - Trying to set a specific frequency, but userspace governor is not available,
       for example because of hardware which cannot be set to a specific frequency
       or because the userspace governor isn't loaded?
#

I started troubleshooting:

# cpupower frequency-info
analyzing CPU 0:
  no or unknown cpufreq driver is active on this CPU
  CPUs which run at the same hardware frequency: Not Available
  CPUs which need to have their frequency coordinated by software: Not Available
  maximum transition latency:  Cannot determine or is not supported.
Not Available
  available cpufreq governors: Not Available
  Unable to determine current policy
  current CPU frequency: Unable to call hardware
  current CPU frequency:  Unable to call to kernel
  boost state support:
    Supported: yes
    Active: yes
    Boost States: 0
    Total States: 3
    Pstate-P0:  2000MHz
    Pstate-P1:  1800MHz
    Pstate-P2:  1500MHz
#
# ls /sys/devices/system/cpu/cpufreq/
<Empty>
#
#

For whatever reason, it thinks that cpufreq drivers are missing. However, the kernel .config has the following enabled:

CONFIG_CPU_FREQ=y
CONFIG_X86_ACPI_CPUFREQ=y
CONFIG_X86_ACPI_CPUFREQ_CPB=y
CONFIG_X86_INTEL_PSTATE=y
CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y
CONFIG_CPU_FREQ_GOV_PERFORMANCE=y
CONFIG_CPU_FREQ_GOV_ONDEMAND=y

I did try to disable CONFIG_X86_INTEL_PSTATE and add CONFIG_X86_POWERNOW_K8 (the only AMD-specific in the current kernel), but it didn't seem to help. Does this mean my kernel version has no full support for AMD power-related features? Do I have an option except upgrading the kernel?

0 Likes
2 Replies
cruz7
Journeyman III

Re: can't set cpu frequency governor with cpupower on AMD EPYC 7702P

So, I took some time to debug the drivers behaviour -- ``"drivers/cpufreq/cpufreq.c" and "drivers/cpufreq/acpi-cpufreq.c" and found that the driver acpi-cpufreq actually fails with message:

ACPI-based processor performance control unavailable

 

As far as I understand, in the driver attempts to read _PCT object from ACPI table and fails, because can't find it.

Does this mean that the BIOS on this machine has no full support of ACPI, or CPU microcode needs to be updated, or the kernel is missing something?

0 Likes
ydalex
Journeyman III

Re: can't set cpu frequency governor with cpupower on AMD EPYC 7702P

Hi,
Don't know about HPE but I had a similar problem on a Dell server. The problem was that the BIOS was controlling the CPU freq. Changing the setting to handover the control to the OS solved it. Don't know what is better BIOS or OS but I guess the OS can make a better decision.

0 Likes