9

I've noticed that powertop utility reports "Bad" "Runtime PM for PCI Device" for several devices. Seems that powertop can fix the issue but it won't tell what exactly it does to fix it. What should I do to fix that "Runtime PM..." issue?

akaihola
  • 164
  • 8
Alexey B.
  • 191
  • 1
  • 1
  • 4

4 Answers4

5

Create a file called /etc/udev/rules.d/10-runtime-pm.rules with the following content:

SUBSYSTEM!="pci", GOTO="power_runtime_rules_end"
ACTION!="add", GOTO="power_runtime_rules_end"

KERNEL=="????:??:??.?"
PROGRAM="/bin/sleep 0.1"

ATTR{power/control}=="*", ATTR{power/control}="auto"

LABEL="power_runtime_rules_end"

After a reboot runtime PM should be enabled for all devices that support it. It is also enables it for all hotplugged devices.

Fabian Henze
  • 213
  • 3
  • 6
4

You need to set power/control attribute to auto for these devices. The easiest way to set it immediately for all PCI devices is:

echo auto | sudo tee /sys/bus/pci/devices/*/power/control 

Bash complains when using output redirection (>) to multiple files as ambiguous redirect.

If you want to set it permanently use approach described in this answer.

kravemir
  • 151
  • 4
3

Since the bios 2.11 update on the UX32VD this rule breaks usb device auto detection. I don't really know how, but since then to detect usb devices, the xhci_hcd module must be reloaded after a usb devce is connected to detect it.

bugmenot
  • 31
  • 1
2

This CrunchBang Linux forum thread helped me to solve this.

You enable PM for each of your PCI devices this way :

echo auto > /sys/bus/pci/devices/*/power/control 

The forum thread shows a nice powersaving script btw.

suriv
  • 103
  • 4
Bathz
  • 121
  • 7
  • Link is dead, archive link: https://web.archive.org/web/20150207164556/http://crunchbang.org/forums/viewtopic.php?id=11954 – Dark May 05 '19 at 11:42