6.5 kernel and AMD pstate driver as default

,

Hi everyone, I’ve installed today a 6.5.0-57.fc40.x86_64 kernel on my F38 machine to give it a quick look of where things are and left a little confused in regards to the amd pstate driver.

According to this article kernel 6.5 supposed to be running with amd_pstate=active. While I’ve been running with this parameter manually added since the release of 6.4 kernel, 6.5.0-57.fc40.x86_64 is still defaults to acpi cpufreq driver.

Is this something configured on compile? I find new pstate driver running very performant and cool on my Ryzen 5900X, so I’m curious if that will be a default for Fedora provided kernels going forward?

1 Like

I installed kernel 6.5.2-300.fc39.x86_64 on F38 today just to test and acpi-cpufreq was still on by default. It was easy to change to amd-pstate, though, by adding amd_pstate=guidedin the grub configuration for the kernel.

Could this be dependent on some more specific hardware/bios - I wonder.
I’ve tried all valuse for amd_pstate and still I end up with acpi-cpufreq
I’m on a Lenovo Thinkpad E14 gen2 - anybody? Thanks.

Don’t qoute me on that, but the description says:

Currently, some of the Zen2 and Zen3 processors support amd-pstate

iirc only Desktop Zen2 CPUs are supported and Zen3 on a mobile, or Zen2+

It’s easy, but people need to know that it needs to be enabled, which is not the majority of users and it’s leaving performance and cooling capacity on the table, hence my original question: what’s up with defaults

I just got the 6.5.5 update for on my Fedora 38 desktop. Out of curiosity I checked if p_state was active and it wasn’t.

The Fedora kernel is built with CONFIG_X86_AMD_PSTATE_DEFAULT_MODE=3, which is Active (EPP), so apparently something in my hardware configuration is disabling it unless forced on.

Following up with myself. At least on my system (5800x3d, Gigabyte X570S Aorus Elite) I cannot find a set of UEFI settings that make cppc appear as available (lscpu | grep cppc) so I guess I’m out of luck troubleshooting this further.

As a data point, I switched my machine to amd_pstate=passive because I like to apply more aggressive power saving than the active + powersave governor were providing on my machine and it regressed my battery runtimes vs the acpi driver because of that.

Particularly, the active mode wasn’t honoring my max frequency clamp, which I apply to keep the machine from boosting well into the diminishing returns region. In return, I can go well into the 10+ hour runtime ranges with a 62Wh battery.

I don’t have cppc listed in cpu flags as well on my 5900X, but it works just fine when manually activated

Yep, adding amd_pstate=active to the kernel arguments makes it work.

What I cannot find is any combination of anything to make it “used by default” as mentioned in the article. I’m pretty sure it’s not because of the Fedora kernel config, but some check in the kernel itself.

@jforbes hi there, can you weigh in on this topic? Sorry to tag you directly, but you are the right person to answer our questions here :slight_smile:

A large number of AMD CPUs do not expose CPPC in cpu flags. There are patches to work around this and enable pstate on those systems, but they are not in stable. I am not sure they will be backported to the 6.5 series.

1 Like

Thanks a lot for clarification!

Same story with kernel 6.6.4. I assume our CPUs use the “shared memory” P-state implementation.

I think that means we’re waiting for resolution of this TODO item. Unfortunately I don’t know of a good place to track progress.

Squaring the circle on this, the TODO has been cleared (see also this bug), I don’t see any evidence of it being backported to 6.10, but I think we’ll be seeing this by 6.11.