Udev rule not working after upgrade to Fedora 41

Hello, I have noticed that my SSDs are getting boiling hot after upgrade to F41. I realized that my link_power_management_policy rule is not applied as used to be applied in F40.

cat /etc/udev/rules.d/99-hd_power_save.rules
ACTION=="add", SUBSYSTEM=="scsi_host", KERNEL=="host*", ATTR{link_power_management_policy}="med_power_with_dipm"
udevadm info --attribute-walk /sys/class/scsi_host/host1
...
  looking at device '/devices/pci0000:00/0000:00:17.0/ata2/host1/scsi_host/host1':
    KERNEL=="host1"
    SUBSYSTEM=="scsi_host"
    DRIVER==""
...
udevadm test /sys/devices/pci0000:00/0000:00:17.0/ata2/host1/scsi_host/host1
...
Reading rules file: /usr/lib/udev/rules.d/98-kexec.rules
Reading rules file: /etc/udev/rules.d/99-hd_power_save.rules
Reading rules file: /usr/lib/udev/rules.d/99-nfs.rules
Reading rules file: /usr/lib/udev/rules.d/99-qemu-guest-agent.rules
Reading rules file: /usr/lib/udev/rules.d/99-systemd.rules
Reading rules file: /usr/lib/udev/rules.d/99-vmware-scsi-udev.rules
host1: /etc/udev/rules.d/99-hd_power_save.rules:2 Running in test mode, skipping writing ATTR{/sys/devices/pci0000:00/0000:00:17.0/ata2/host1/scsi_host/host1/link_power_management_policy}="med_power_with_dipm".
...

Please point me what I am missing here. Could tuned be the reason somehow?

When I made a udev script for x86_energy_perf_policy, I removed tuned too because it interfered/overrode it (I think technically it was GNOME and the Balanced/Save/Performance power setting, but that goes through tuned)

You can probably find the specific part of tuned that’s changing the setting, but I consider tuned like TLP and don’t like the idea of something else doing power-management outside the kernel and hardware. The only thing I want power-saving on my laptop automatically is my CPU with Intel’s policy.

Thanks. Spot on. Indeed it’s tuned. Probably I should RTFM more precisely :wink: as I just flipped it through briefly. Right now my active profile is balanced and there is a setting in config /usr/lib/tuned/profiles/balanced/tuned.conf:

[scsi_host]
alpm=medium_power

I will try to copy this profile and adjust this particular setting.

Edit: Let me summarize how I have solved this issue. I created a profile file /etc/tuned/profiles/my-profile/tuned.conf

#
# tuned configuration
#

[main]
summary=My tuned profile
include=balanced

[scsi_host]
alpm=med_power_with_dipm

and changed /etc/tuned/ppd.conf to point balanced to this new profile:

[main]
# The default PPD profile
default=balanced
battery_detection=true

[profiles]
# PPD = TuneD
power-saver=powersave
balanced=my-profile
performance=throughput-performance

[battery]
# PPD = TuneD
balanced=balanced-battery

I am not sure whether it is the right way to do this, but at least it works.

1 Like