提交 6b87e700 编写于 作者: A Andrew Murray 提交者: Bjorn Helgaas

PCI: Update pcie_ports 'auto' behavior for non-ACPI platforms

The pcie_ports parameter, which defaults to 'auto', allows a user
to specify if PCIe port services are disabled ('compat'), always
enabled ('native'), or only used when allowed by the BIOS
('auto').

Where CONFIG_ACPI isn't enabled, as is often the case for non
x86/ia64 platforms, the 'auto' behavior results in that of
'compat'. Thus in order to use port services on these platforms
'pcie_ports=native' must be added to the kernel command line.

This patch results in the 'native' behavior being followed where
'auto' is selected and ACPI is not enabled.
Signed-off-by: NAndrew Murray <amurray@embedded-bits.co.uk>
Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
上级 0394cb19
...@@ -260,13 +260,14 @@ static int get_port_device_capability(struct pci_dev *dev) ...@@ -260,13 +260,14 @@ static int get_port_device_capability(struct pci_dev *dev)
if (pcie_ports_disabled) if (pcie_ports_disabled)
return 0; return 0;
err = pcie_port_platform_notify(dev, &cap_mask); cap_mask = PCIE_PORT_SERVICE_PME | PCIE_PORT_SERVICE_HP
if (!pcie_ports_auto) { | PCIE_PORT_SERVICE_VC;
cap_mask = PCIE_PORT_SERVICE_PME | PCIE_PORT_SERVICE_HP if (pci_aer_available())
| PCIE_PORT_SERVICE_VC; cap_mask |= PCIE_PORT_SERVICE_AER;
if (pci_aer_available())
cap_mask |= PCIE_PORT_SERVICE_AER; if (pcie_ports_auto) {
} else if (err) { err = pcie_port_platform_notify(dev, &cap_mask);
if (err)
return 0; return 0;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册