How to switch back to acpi-cpufreq? (linux kernel 6.5.4)

bominyarou

New Member
Joined
Oct 6, 2023
Messages
3
Reaction score
0
Credits
34
Hello there. I'm not very educated with linux commands and programming, so I'm here asking for help.
Is there any way I can switch back to acpi-cpufreq from amd-pstate-epp? (which has set by default after kernel 6.5.4 update)

My situation is that I live in a caribbean country (kinda poor, and so am I), and I take care of my only laptop like its a precious treasure. The laptop gets easily hot, specially in the afternoon when temps get around 40°C or higher. Before this update that put amd-pstate-epp as default driver, I used an app called "cpupower-gui" to control my cpu freqs, and had a crontab on reboot to disable boost, so that it would never get over 70°C in my laptop, that way my battery and my laptop itself can live as long as it possibly can. But, after this update, the cpupower-gui is kinda useless, and my laptop keeps overheating just by opening websites or watching YT vids.

If there is a way to remove amd-pstate-epp and put acpi-cpufreq back, please let me know~
 


As a temporary measure, you can enter boot menu [when you switch on] select advanced options and choose to boot the previous Kernel
 
Depending on your distro, you may be able to install these tools.

cpupower

and then run....

cpupower frequency-info

cpupower frequency-set -g acpi-cpufreq


However, you will need to create something like a systemd service file to make this persistent after a reboot.
 
Depending on your distro, you may be able to install these tools.

cpupower

and then run....

cpupower frequency-info

cpupower frequency-set -g acpi-cpufreq


However, you will need to create something like a systemd service file to make this persistent after a reboot.
I'm using Pop_Os 22.04 (Ubuntu based distro). I should try doing that. How do I make a systemd file to make it persistent?
Edit: I tried what you wrote above and I got this error:
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?"
Did they completely remove acpi-cpufreq from the system after the kernel update or something? x.x
 

amd-pstate vs acpi-cpufreq​


On the majority of AMD platforms supported by acpi-cpufreq, the ACPI tables provided by the platform firmware are used for CPU performance scaling, but only provide 3 P-states on AMD processors. However, on modern AMD APU and CPU series, hardware provides the Collaborative Processor Performance Control according to the ACPI protocol and customizes this for AMD platforms. That is, fine-grained and continuous frequency ranges instead of the legacy hardware P-states. amd-pstate is the kernel module which supports the new AMD P-States mechanism on most of the future AMD platforms. The AMD P-States mechanism is the more performance and energy efficiency frequency management method on AMD processors.

the above is an extract from this article

 
To make it persistent, copy this text to cpu-governor.service
Then put this file in /usr/lib/systemd/system
-------------------------------------------------------------

[Unit]
Description=Set CPU governor to acpi-cpufreq

[Service]
Type=oneshot
ExecStart=/usr/bin/cpupower frequency-set -g acpi-cpufreq

[Install]
WantedBy=multi-user.target

--------------------------------------------------------------

Save the file and exit your text editor.

Enable the service to start at boot:

sudo systemctl enable cpu-governor.service

Start the service manually for the current session:

sudo systemctl start cpu-governor.service

-------------------------------------------

However if it doesn't work manually, it won't work from a systemd file.
Are you running this commands as root or with sudo?
 
To make it persistent, copy this text to cpu-governor.service
Then put this file in /usr/lib/systemd/system
-------------------------------------------------------------

[Unit]
Description=Set CPU governor to acpi-cpufreq

[Service]
Type=oneshot
ExecStart=/usr/bin/cpupower frequency-set -g acpi-cpufreq

[Install]
WantedBy=multi-user.target

--------------------------------------------------------------

Save the file and exit your text editor.

Enable the service to start at boot:

sudo systemctl enable cpu-governor.service

Start the service manually for the current session:

sudo systemctl start cpu-governor.service

-------------------------------------------

However if it doesn't work manually, it won't work from a systemd file.
Are you running this commands as root or with sudo?
I was running with sudo and it gave me error. I'll try this one you say and see if it works.
 
@bominyarou I have a solution just for you. I'm also using pop2204, and had exactly the same problem after a recent upgrade, which upgraded core to 6.5.

The solution is very simple:
Bash:
$ sudo kernelstub -a amd_pstate=disable

This will add a kernel boot flag to disable amd_pstate completely. Just setting it to passive mode made no effect on power consumption.

You can verify that the flag is applied with:
Bash:
$ sudo bootctl list
Boot Loader Entries:
        title: Pop!_OS (Pop_OS-current.conf) (default)
           id: Pop_OS-current.conf
       source: /boot/efi/loader/entries/Pop_OS-current.conf
        linux: /EFI/Pop_OS-07beaf5b-f028-4776-a725-f5e67768a896/vmlinuz.efi
       initrd: /EFI/Pop_OS-07beaf5b-f028-4776-a725-f5e67768a896/initrd.img
      options: root=UUID=07beaf5b-f028-4776-a725-f5e67768a896 ro amd_pstate=disable amdgpu.dcdebugmask=0x10

        title: Pop!_OS (Pop_OS-oldkern.conf)
           id: Pop_OS-oldkern.conf
       source: /boot/efi/loader/entries/Pop_OS-oldkern.conf
        linux: /EFI/Pop_OS-07beaf5b-f028-4776-a725-f5e67768a896/vmlinuz-previous.efi
       initrd: /EFI/Pop_OS-07beaf5b-f028-4776-a725-f5e67768a896/initrd.img-previous
      options: root=UUID=07beaf5b-f028-4776-a725-f5e67768a896 ro amd_pstate=disable amdgpu.dcdebugmask=0x10

        title: Reboot Into Firmware Interface
           id: auto-reboot-to-firmware-setup
       source: /sys/firmware/efi/efivars/LoaderEntries-4a67b082-0a4c-41cf-b6c7-440b29bb8c4f

you should see the "amd_pstate=disable" in the "options" line. Also this fix is permanent, and will be automatically applied to future kernels.

P.S. @Brickwizard although some benchmarks say amd_pstate is better performance/powersave, for me it gave just absolutely garbage battery life with R7 6850U. Previously, with boosting disabled, and max frequency limited to 2.7GHz, I easily had over 10-12h general text-browser runtime (no videos). With amd_pstate I get not more than 6 hours (and almost constant fan on).
 
Last edited:
@Brickwizard although some benchmarks say amd_pstate is better performance/powersave, for me it gave just absolutely garbage battery life with R7 6850U. Previously, with boosting disabled, and max frequency limited to 2.7GHz, I easily had over 10-12h general text-browser runtime (no videos). With amd_pstate I get not more than 6 hours (and almost constant fan on).
I will remember that thanks for your report
 

Members online


Latest posts

Top