PCI: Change default MPS behavior
RFC 1/1 PCI: Change default MPS behavior
Not all systems have a BIOS or firmware to preconfigure the PCIE MPS prior to Linux booting. Without any firmware to pre-setup the MPS, the PCIE_BUS_DEFAULT will simply set everything to 0 (128b). This behavior causes these systems to have non-optimal MPS values. To get around this issue, change the default value of pcie_bus_config to be PCIE_BUS_SAFE. This configures all systems to use better values for the MPS, at the expense of any potential HW errata that might not like being changed.
--- drivers/pci/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pci/pci.c +1 -1
@@ -88,7 +88,7 @@ unsigned long pci_hotplug_mem_size = DEFAULT_HOTPLUG_MEM_SIZE;#define DEFAULT_HOTPLUG_BUS_SIZE 1unsigned long pci_hotplug_bus_size =DEFAULT_HOTPLUG_BUS_SIZE ; -enum pcie_bus_config_types pcie_bus_config =PCIE_BUS_DEFAULT ; +enum pcie_bus_config_types pcie_bus_config =PCIE_BUS_SAFE ;/* * The default CLS is used if arch didn't set CLS explicitly and not
Signature · 1 line
2.7.4
Quoted 7 lines · Jon Mason
Not all systems have a BIOS or firmware to preconfigure the PCIE MPS prior to Linux booting. Without any firmware to pre-setup the MPS, the
PCIE_BUS_DEFAULTwill simply set everything to 0 (128b). This behavior causes these systems to have non-optimal MPS values. To get around this issue, change the default value ofpcie_bus_configto bePCIE_BUS_SAFE. This configures all systems to use better values for the MPS, at the expense of any potential HW errata that might not like being changed.
Wouldn't it be better to provide the kernel parameter to override the default on such platforms? The PCIE_BUS_SAFE sets the MPS to the lowest common denominator below the root port, which may be less optimal than the default behavior for hot plug.