Power-Profiles-Daemon not Working Correctly Sometimes

Hello, I get an inconsistent issue with the kde power-profiles-daemon that lets you switch between performance, balanced, and power-saving modes. Sometimes the feature does not work and trying to move the slider in the system tray app sends an error notification saying “Failed to activate balanced mode” (or whatever mode was selected). Thing is sometimes it works when I first turn on the computer, and sometimes it will work after one or more restarts, and I don’t understand why. Any advice on how to make it work consistently is appreciated.

I checked systemctl status power-profiles-daemon and got the following output. Obviously something is not working correctly, but I’m not sure what to do to fix it.

● power-profiles-daemon.service - Power Profiles daemon
     Loaded: loaded (/usr/lib/systemd/system/power-profiles-daemon.service; enabled; preset: disabled)
     Active: active (running) since Wed 2023-10-11 14:09:36 EDT; 2h 4min ago
   Main PID: 653 (power-profiles-)
      Tasks: 4 (limit: 38172)
     Memory: 5.3M
        CPU: 156ms
     CGroup: /system.slice/power-profiles-daemon.service
             └─653 /usr/lib/power-profiles-daemon

Oct 11 14:09:36 weds4-20hjs7dg00 systemd[1]: Started Power Profiles daemon.
Oct 11 15:53:13 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 15:53:19 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 15:53:19 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 16:03:07 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 16:03:07 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 16:03:07 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 16:12:00 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 16:12:00 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy
Oct 11 16:12:00 weds4-20hjs7dg00 power-profiles-[653]: Failed to activate driver 'intel_pstate': Error writing '/sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference': Device or resource busy

My garuda-inxi is below.

garuda-inxi
System:
Kernel: 6.5.5-zen1-1-zen arch: x86_64 bits: 64 compiler: gcc v: 13.2.1
clocksource: tsc available: acpi_pm
parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
root=UUID=f6de50df-1b53-4507-a69d-8201ec25043a rw rootflags=subvol=@
quiet quiet rd.udev.log_priority=3 vt.global_cursor_default=0 loglevel=3
ibt=off
Desktop: KDE Plasma v: 5.27.8 tk: Qt v: 5.15.11 wm: kwin_x11 vt: 2
dm: SDDM Distro: Garuda Linux base: Arch Linux
Machine:
Type: Laptop System: LENOVO product: 20HJS7DG00 v: ThinkPad P51
serial: <superuser required> Chassis: type: 10 serial: <superuser required>
Mobo: LENOVO model: 20HJS7DG00 v: SDK0Q40112 WIN
serial: <superuser required> UEFI: LENOVO v: N1UET86W (1.60 )
date: 11/30/2022
Battery:
ID-1: BAT0 charge: 69.5 Wh (99.0%) condition: 70.2/90.0 Wh (78.0%)
power: 5.2 W volts: 12.9 min: 11.2 model: SMP 00NY493 type: Li-poly
serial: <filter> status: charging cycles: 967
CPU:
Info: model: Intel Xeon E3-1505M v6 bits: 64 type: MT MCP arch: Kaby Lake
level: v3 note: check built: 2018 process: Intel 14nm family: 6
model-id: 0x9E (158) stepping: 9 microcode: 0xF4
Topology: cpus: 1x cores: 4 tpc: 2 threads: 8 smt: enabled cache:
L1: 256 KiB desc: d-4x32 KiB; i-4x32 KiB L2: 1024 KiB desc: 4x256 KiB
L3: 8 MiB desc: 1x8 MiB
Speed (MHz): avg: 3600 min/max: 800/4000 scaling: driver: intel_pstate
governor: performance cores: 1: 3600 2: 3600 3: 3600 4: 3600 5: 3600 6: 3600
7: 3600 8: 3600 bogomips: 48000
Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Vulnerabilities: <filter>
Graphics:
Device-1: Intel HD Graphics P630 vendor: Lenovo driver: i915 v: kernel
arch: Gen-9.5 process: Intel 14nm built: 2016-20 ports: active: eDP-1
empty: none bus-ID: 00:02.0 chip-ID: 8086:591d class-ID: 0300
Device-2: NVIDIA GM206GLM [Quadro M2200 Mobile] vendor: Lenovo
driver: nvidia v: 535.113.01 alternate: nouveau,nvidia_drm non-free: 535.xx+
status: current (as of 2023-09) arch: Maxwell code: GMxxx
process: TSMC 28nm built: 2014-19 pcie: gen: 1 speed: 2.5 GT/s lanes: 16
link-max: gen: 3 speed: 8 GT/s bus-ID: 01:00.0 chip-ID: 10de:1436
class-ID: 0302
Device-3: Chicony Integrated Camera driver: uvcvideo type: USB rev: 2.0
speed: 480 Mb/s lanes: 1 mode: 2.0 bus-ID: 1-8:2 chip-ID: 04f2:b5ab
class-ID: 0e02
Display: x11 server: X.Org v: 21.1.8 with: Xwayland v: 23.2.1
compositor: kwin_x11 driver: X: loaded: modesetting,nvidia unloaded: nouveau
alternate: fbdev,intel,nv,vesa dri: iris gpu: i915 display-ID: :0
screens: 1
Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 507x285mm (19.96x11.22")
s-diag: 582mm (22.9")
Monitor-1: eDP-1 model: AU Optronics 0x21eb built: 2016 res: 1920x1080
hz: 60 dpi: 141 gamma: 1.2 size: 345x194mm (13.58x7.64") diag: 396mm (15.6")
ratio: 16:9 modes: 3840x2160
API: EGL v: 1.5 hw: drv: intel iris drv: nvidia platforms: device: 0
drv: nvidia device: 1 drv: iris device: 3 drv: swrast surfaceless:
drv: nvidia x11: drv: iris inactive: gbm,wayland,device-2
API: OpenGL v: 4.6.0 compat-v: 4.5 vendor: intel mesa v: 23.2.1-arch1.2
glx-v: 1.4 direct-render: yes renderer: Mesa Intel HD Graphics P630 (KBL
GT2) device-ID: 8086:591d memory: 30.46 GiB unified: yes
API: Vulkan v: 1.3.264 layers: 14 device: 0 type: integrated-gpu
name: Intel HD Graphics P630 (KBL GT2) driver: mesa intel v: 23.2.1-arch1.2
device-ID: 8086:591d surfaces: xcb,xlib device: 1 type: discrete-gpu
name: Quadro M2200 driver: nvidia v: 535.113.01 device-ID: 10de:1436
surfaces: xcb,xlib device: 2 type: cpu name: llvmpipe (LLVM 16.0.6 256
bits) driver: mesa llvmpipe v: 23.2.1-arch1.2 (LLVM 16.0.6)
device-ID: 10005:0000 surfaces: xcb,xlib
Audio:
Device-1: Intel CM238 HD Audio vendor: Lenovo driver: snd_hda_intel
v: kernel alternate: snd_soc_avs bus-ID: 00:1f.3 chip-ID: 8086:a171
class-ID: 0403
Device-2: NVIDIA GM206 High Definition Audio driver: snd_hda_intel
v: kernel pcie: gen: 3 speed: 8 GT/s lanes: 16 bus-ID: 01:00.1
chip-ID: 10de:0fba class-ID: 0403
API: ALSA v: k6.5.5-zen1-1-zen status: kernel-api with: aoss
type: oss-emulator tools: N/A
Server-1: PipeWire v: 0.3.81 status: active with: 1: pipewire-pulse
status: active 2: wireplumber status: active 3: pipewire-alsa type: plugin
4: pw-jack type: plugin tools: pactl,pw-cat,pw-cli,wpctl
Network:
Device-1: Intel Ethernet I219-LM vendor: Lenovo driver: e1000e v: kernel
port: N/A bus-ID: 00:1f.6 chip-ID: 8086:15e3 class-ID: 0200
IF: enp0s31f6 state: down mac: <filter>
Device-2: Intel Wireless 8265 / 8275 driver: iwlwifi v: kernel pcie:
gen: 1 speed: 2.5 GT/s lanes: 1 bus-ID: 04:00.0 chip-ID: 8086:24fd
class-ID: 0280
IF: wlp4s0 state: up mac: <filter>
Drives:
Local Storage: total: 953.87 GiB used: 56.75 GiB (5.9%)
SMART Message: Unable to run smartctl. Root privileges required.
ID-1: /dev/nvme0n1 maj-min: 259:0 model: PCIe SSD size: 953.87 GiB
block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s lanes: 4
tech: SSD serial: <filter> fw-rev: H230331a temp: 39.9 C scheme: GPT
Partition:
ID-1: / raw-size: 224 GiB size: 224 GiB (100.00%) used: 56.72 GiB (25.3%)
fs: btrfs dev: /dev/nvme0n1p5 maj-min: 259:5
ID-2: /boot/efi raw-size: 100 MiB size: 96 MiB (96.00%)
used: 25.8 MiB (26.9%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
ID-3: /home raw-size: 224 GiB size: 224 GiB (100.00%)
used: 56.72 GiB (25.3%) fs: btrfs dev: /dev/nvme0n1p5 maj-min: 259:5
ID-4: /var/log raw-size: 224 GiB size: 224 GiB (100.00%)
used: 56.72 GiB (25.3%) fs: btrfs dev: /dev/nvme0n1p5 maj-min: 259:5
ID-5: /var/tmp raw-size: 224 GiB size: 224 GiB (100.00%)
used: 56.72 GiB (25.3%) fs: btrfs dev: /dev/nvme0n1p5 maj-min: 259:5
Swap:
Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default) zswap: no
ID-1: swap-1 type: zram size: 31.19 GiB used: 5.5 MiB (0.0%) priority: 100
comp: zstd avail: lzo,lzo-rle,lz4,lz4hc,842 max-streams: 8 dev: /dev/zram0
Sensors:
System Temperatures: cpu: 92.0 C pch: 59.0 C mobo: N/A
Fan Speeds (rpm): fan-1: 4491 fan-2: 4492
Info:
Processes: 285 Uptime: 2h 0m wakeups: 1 Memory: total: 32 GiB
available: 31.19 GiB used: 5.57 GiB (17.8%) Init: systemd v: 254
default: graphical tool: systemctl Compilers: gcc: 13.2.1 Packages:
pm: pacman pkgs: 2019 libs: 574 tools: octopi,paru Shell: fish v: 3.6.1
default: Bash v: 5.1.16 running-in: konsole inxi: 3.3.30
Garuda (2.6.17-1):
System install date:     2023-09-17
Last full system update: 2023-10-11 ↻
Is partially upgraded:   No
Relevant software:       snapper NetworkManager dracut nvidia-dkms
Windows dual boot:       Probably (Run as root to verify)
Failed units:

Is there a difference when you reboot from windows to Garuda or when you shut down windows and then boot Garuda?

Not sure. I haven’t booted windows since installing Garuda tbh (about a month). It’s a refurbished laptop that came with W10 so I got linux going and just haven’t bothered uninstalling windows yet. I can’t get the issue to reliably occur, so I’m not sure how effective testing windows vs linux reboots will be. I can give it a try.

Ok, finally had time to test this. I restarted several times. Each time the system was powered on for only a minute or two - long enough to test if the power mode switch was functional. The chronology is below:
0. Before starting I ran a system update. Then I powered off the system.

  1. Booted into Garuda. Power mode was stuck in powersaver.
  2. Rebooted (using restart) into Windows 10. I chose Windows 10 from Grub, not from the UEFE menu. Windows’ version of the power mode was functional. I left Windows in powersaver mode.
  3. Rebooted (using Windows’ restart) into Garuda. I just let Grub autoselect Garuda (how I normally boot the computer). Power mode was stuck in performance.
  4. Rebooted to Garuda (using restart). Power mode was stuck in powersaver.
  5. Rebooted (by using shutdown) into Garuda. Power mode was in balanced and was not stuck.

Hope this helps narrow down some possibilities.
Thanks!

Interestingly, I ran an update today and noticed this error in the output: Failed to write file "/sys/module/pcie_aspm/parameters/policy": Operation not permitted error: command failed to execute correctly
Before updating I confirmed that the power mode slider was working. After the update, the slider is broken again.

I found this post related to the error: Failed to write file "/sys/module/pcie_aspm/parameters/policy": Operation not permitted - #8 by filo

and that has a link to this page regarding power management:
https://wiki.archlinux.org/title/Power_management#Active_State_Power_Management

However, I haven’t been able to put anything together to figure out my issue yet. Any advice?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.