summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/libxed.py
diff options
context:
space:
mode:
authorIlpo Järvinen <ilpo.jarvinen@linux.intel.com>2023-09-18 16:10:53 +0300
committerBjorn Helgaas <bhelgaas@google.com>2026-10-15 17:55:09 -0500
commit2cbfd6c8dcfc9c5539d0ffca22b5609593f93c03 (patch)
tree8a2f09d944711b51b410232926874d4fefb869f0 /tools/perf/scripts/python/libxed.py
parentcee9395acd8043be0644b25c34bfa86623f2b935 (diff)
PCI/ASPM: Disable ASPM when driver requests it
PCI core/ASPM service driver allows controlling ASPM state through pci_disable_link_state() and pci_enable_link_state() API. It was decided earlier (see the Link below), to not allow ASPM changes when OS does not have control over it but only log a warning about the problem (commit 2add0ec14c25 ("PCI/ASPM: Warn when driver asks to disable ASPM, but we can't do it")). Similarly, if ASPM is not enabled through config, ASPM cannot be disabled. A number of drivers have added workarounds to force ASPM off with own writes into the Link Control Register (some even with comments explaining why PCI core does not disable it under some circumstances). According to the comments, some drivers require ASPM to be off for reliable operation. Having custom ASPM handling in drivers is problematic because the state kept in the ASPM service driver is not updated by the changes made outside the link state management API. As the first step to address this issue, make pci_disable_link_state() unconditionally disable ASPM so the motivation for drivers to come up with custom ASPM handling code is eliminated. Make pci_disable_link_state() function comment to comply kerneldoc formatting while changing the description. [bhelgaas: To take advantage of the PCI core ASPM handling, drivers that need to quirk ASPM should depend on CONFIG_PCIEASPM and have their custom ASPM code removed.] Link: https://lore.kernel.org/all/CANUX_P3F5YhbZX3WGU-j1AGpbXb_T9Bis2ErhvKkFMtDvzatVQ@mail.gmail.com/ Link: https://lore.kernel.org/all/20230511131441.45704-1-ilpo.jarvinen@linux.intel.com/ Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> [bhelgaas: extract just the aspm.c change and update commit log] Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Link: https://patch.msgid.link/20230918131103.24119-4-ilpo.jarvinen@linux.intel.com
Diffstat (limited to 'tools/perf/scripts/python/libxed.py')
0 files changed, 0 insertions, 0 deletions