Skip to content

Commit ea5f9fc

Browse files
Matthew Garrettjbarnes993
authored andcommitted
PCI: Default PCIe ASPM control to on and require !EMBEDDED to disable
The CONFIG_PCIEASPM option is confusing and potentially dangerous. ASPM is a hardware mediated feature rather than one under direct OS control, and even if the config option is disabled the system firmware may have turned on ASPM on various bits of hardware. This can cause problems later - various hardware that claims to support ASPM does a poor job of it and may hang or cause other difficulties. The kernel is able to recognise this in many cases and disable the ASPM functionality, but only if CONFIG_PCIEASPM is enabled. Given that in its default configuration this option will either leave the hardware as it was originally or disable hardware functionality that may cause problems, it should by default y. The only reason to disable it ought to be to reduce code size, so make it dependent on CONFIG_EMBEDDED. Signed-off-by: Matthew Garrett <[email protected]> Cc: [email protected] Cc: [email protected] Signed-off-by: Jesse Barnes <[email protected]>
1 parent 8cc2bfd commit ea5f9fc

File tree

1 file changed

+14
-6
lines changed

1 file changed

+14
-6
lines changed

drivers/pci/pcie/Kconfig

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,22 @@ source "drivers/pci/pcie/aer/Kconfig"
3131
# PCI Express ASPM
3232
#
3333
config PCIEASPM
34-
bool "PCI Express ASPM support(Experimental)"
35-
depends on PCI && EXPERIMENTAL && PCIEPORTBUS
36-
default n
34+
bool "PCI Express ASPM control" if EMBEDDED
35+
depends on PCI && PCIEPORTBUS
36+
default y
3737
help
38-
This enables PCI Express ASPM (Active State Power Management) and
39-
Clock Power Management. ASPM supports state L0/L0s/L1.
38+
This enables OS control over PCI Express ASPM (Active State
39+
Power Management) and Clock Power Management. ASPM supports
40+
state L0/L0s/L1.
4041

41-
When in doubt, say N.
42+
ASPM is initially set up the the firmware. With this option enabled,
43+
Linux can modify this state in order to disable ASPM on known-bad
44+
hardware or configurations and enable it when known-safe.
45+
46+
ASPM can be disabled or enabled at runtime via
47+
/sys/module/pcie_aspm/parameters/policy
48+
49+
When in doubt, say Y.
4250
config PCIEASPM_DEBUG
4351
bool "Debug PCI Express ASPM"
4452
depends on PCIEASPM

0 commit comments

Comments
 (0)