cpupower icon indicating copy to clipboard operation
cpupower copied to clipboard

Switch to other profile impossible

Open jeed2424 opened this issue 3 years ago • 8 comments

cpu: i7-6500u gnome version: 3.36.8 Linux Kernel: 5.4.0-58-generic

When I select a profile other than the first one on my list, the profile gets switched back to the first one within seconds.

*See video for better explanation.

https://user-images.githubusercontent.com/50756835/140802629-c75bd991-33f9-4b92-81ba-9237ae856fb3.mp4

jeed2424 avatar Nov 08 '21 19:11 jeed2424

I had this issue as well, found out it was because I had CPU power features disabled in the BIOS. (Writes to /sys/devices/system/cpu/intel_pstate/no_turbo were faililng). Still does some weird things such as not setting minimum CPU frequency below 45%, probably it's the same thing, haven't bothered to explore. It will only "stick" on a profile if the settings will stay at those values.

pdragicevich avatar Nov 27 '21 07:11 pdragicevich

@pdragicevich This might have sth to do with the minimum supported hardware frequency. The version 10.0.0 of this extension includes a great UI rework by @mastercaution which visualizes this way better than previous versions. Unfortunately, this version is not allowed to be published on the GNOME extensions website unless we drop support for old GNOME versions and do a complete rewrite of our GNOME 40 support. As this has been communicated to us after we finishes all testing and already made the final release, it is unlikely that this version will ever land on the GNOME extensions website. Also, we currently have no time (and especially motivation) for a full rewrite. Therfore you have to manually install the update as described in the README until I (or someone else) gets rpm and deb packages ready (ideally distributed via copr and ppa). I successfully packaged the extension as rpm and deb last week, but haven't had time to integrate it with build services, yet. But if you're patient, you might be able to update via your distributions package manager in the next couple of months.

fin-ger avatar Nov 28 '21 13:11 fin-ger

Same here with ryzen 3900xt of fedora 36. Other than that the stock clock is wrong, it should be 3.8GHz instead of 3.6GHz

https://user-images.githubusercontent.com/8084245/171023057-6c7ab157-7523-42f9-8fa7-94febd5fe450.mp4

Keltere avatar May 30 '22 15:05 Keltere

@Keltere Looks like something else is resetting your frequency preferences (driver or other power tools)

mastercaution avatar May 30 '22 22:05 mastercaution

@Keltere Looks like something else is resetting your frequency preferences (driver or other power tools)

cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_driver 
acpi-cpufreq

Keltere avatar May 31 '22 08:05 Keltere

The acpi-cpufreq driver sometimes has very rough CPU scaling support. In your case (a high-clock gaming CPU) it might be the case that CPU scaling is completely unavailable and your frequency is always at max. In most cases, AMD Ryzen CPUs implement a discrete scaling method (not continuous as in intel-pstate), meaning there are 2 or 3 settings you can set the frequency to. Try to move the slider to e.g. 80% or 70% (seems to be the reported minimum for your CPU). The default profiles do not support this discrete scaling method (yet). Therefore, they are not working. In fact they are working, as you can see that it tries to set the frequency to the desired value, but the hardware rejects it and the GUI mirrors that by resetting the values to the current settings (which are the defaults).

Unfortunately, there is little you can do about it. In the future, I am planning to improve the UX by making the discrete points to which you can set the frequency clear by using markers on the slider. However, I have not found motivation to implement this, yet. I hoped that the cpufreq-scaling driver would eventually get better and I will not have to implement it. Seems like the cpufreq scaling driver is not changing this behavior, so a GUI change seems inevitable.

fin-ger avatar May 31 '22 09:05 fin-ger

What about amd_pstate is that a viable solution?

Keltere avatar May 31 '22 09:05 Keltere

I don't know. But feel free to add a new backend for it:

https://github.com/deinstapel/cpupower/blob/master/tool/cpufreqctl#L301

You have to implement the following functions:

<name>_init
<name>_supported
<name>_reset
<name>_turbo_get
<name>_turbo_set
<name>_min_get
<name>_min_set
<name>_max_get
<name>_max_set
<name>_info_frequencies
<name>_info_current

and integrate it into backends_list, backend_select, help_main, and main.

Looking forward to a PR implementing this!

fin-ger avatar May 31 '22 12:05 fin-ger