You are not logged in.

#1 2021-05-12 07:05:49

pebble
Member
Registered: 2021-05-12
Posts: 5

[SOLVED]AMD CPU no available turbo boost states

Hi.

I recently got a lenovo legion 5 pro laptop with a ryzen r7 5800H cpu

Linux has been working great, even with optimus management, which has just been great.

That said, I just got around to managing CPU frequencies and governors; for that, I am using cpupower and cpupower-gui.

I couldn't help but notice that my maximum available cpu frequency was 3200MHz, which is way below what my cpu is capable of doing. I did some digging, and have enabled the boost flag in /sys/devices/system/cpu/cpufreq/boost. Before this change, the output of

cpupower frequency

was:

analyzing CPU 0:
  driver: acpi-cpufreq
  CPUs which run at the same hardware frequency: 0
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency:  Cannot determine or is not supported.
  hardware limits: 1.20 GHz - 3.20 GHz
  available frequency steps:  3.20 GHz, 1.30 GHz, 1.20 GHz
  available cpufreq governors: conservative ondemand userspace powersave performance schedutil
  current policy: frequency should be within 1.20 GHz and 3.20 GHz.
                  The governor "powersave" may decide which speed to use
                  within this range.
  current CPU frequency: Unable to call hardware
  current CPU frequency: 1.20 GHz (asserted by call to kernel)
  boost state support:
    Supported: yes
    Active: no

After the change, I got

analyzing CPU 0:
  driver: acpi-cpufreq
  CPUs which run at the same hardware frequency: 0
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency:  Cannot determine or is not supported.
  hardware limits: 1.20 GHz - 3.20 GHz
  available frequency steps:  3.20 GHz, 1.30 GHz, 1.20 GHz
  available cpufreq governors: conservative ondemand userspace powersave performance schedutil
  current policy: frequency should be within 1.20 GHz and 3.20 GHz.
                  The governor "powersave" may decide which speed to use
                  within this range.
  current CPU frequency: 1.20 GHz (asserted by call to hardware)
  boost state support:
    Supported: yes
    Active: yes
    Boost States: 0
    Total States: 3
    Pstate-P0:  3200MHz
    Pstate-P1:  1300MHz
    Pstate-P2:  1200MHz

Which at least means that I got cpupower to recognize that boost is active. The problem here, however, is that there are no available boost states, which makes the change entirely a symbolic one.

Is there a way for me to enable boost states, or to add some?

Last edited by pebble (2021-05-12 17:51:44)

Offline

#2 2021-05-12 07:20:18

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 23,447

Re: [SOLVED]AMD CPU no available turbo boost states

This can often be tied to firmware/whether Lenovo/your UEFI is setup to allow this. Are you plugged into the wall with these outputs? Many laptops will implicitly disable boost states on battery you might alsow want to look through your UEFI firmware options.

Offline

#3 2021-05-12 07:33:32

pebble
Member
Registered: 2021-05-12
Posts: 5

Re: [SOLVED]AMD CPU no available turbo boost states

Thanks a lot for the quick response

Plugging in the charger doesn't seem to make a difference. I also haven't seen any related settings in the BIOS

Offline

#4 2021-05-12 09:12:29

Ropid
Member
Registered: 2015-03-09
Posts: 1,069

Re: [SOLVED]AMD CPU no available turbo boost states

Can you check what's happening with "turbostat"? On my desktop Ryzen CPU it shows the boost clock speeds of the CPU. The cpupower tool output is not good, the cpupower tool only shows the base clock speed but will not show how the CPU actually boosts.

You need to use the old version 5.9 of turbostat. The current 5.12 version is broken on Ryzen. It doesn't work at all. You can use the script "downgrade" from the AUR to easily download and install the old Arch turbostat 5.9 package.

You'll need to put some stress on the CPU to see it boosting to its full speed. Running the following at the bash prompt works:

while true; do true; done

Offline

#5 2021-05-12 17:39:17

pebble
Member
Registered: 2021-05-12
Posts: 5

Re: [SOLVED]AMD CPU no available turbo boost states

It does seem to work using that tool. Thank you for the response!

Just couldn't find that anywhere else, so I was worried something might be wrong or that I was missing something. It makes sense that that would be the "issue."

Sorry if my question seemed dumb - I've been using arch for quite a while but have always used intel CPUs, and haven't encountered anything that I felt needed fixing there, so the whole AMD side of things is new to me.

Offline

Board footer

Powered by FluxBB