diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2017-04-19 07:44:51 -0500 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2017-04-19 07:44:51 -0500 |
commit | 9b70ae4951746146838b474c3a90722666edf4c1 (patch) | |
tree | f258fee5780cff49f24d776c8602bad2a08afa88 /drivers/pci/access.c | |
parent | dc5205ef46231e848562c9275933d7b359f515ba (diff) | |
download | linux-9b70ae4951746146838b474c3a90722666edf4c1.tar.bz2 |
PCI: Include PCI-to-PCIe bridges as "Downstream Ports"
A PCI/PCI-X to PCI Express bridge, sometimes referred to as a "reverse
bridge", is a bridge with conventional PCI or PCI-X on its primary side and
a PCI Express Port on its secondary (downstream) side.
That PCIe Port is a Downstream Port and could be connected to a slot, just
like a Root Port or a Switch Downstream Port. Make pcie_downstream_port()
return true for them, so we can access the Slot registers in the PCIe
capability.
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/access.c')
-rw-r--r-- | drivers/pci/access.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/pci/access.c b/drivers/pci/access.c index 1c8051003e67..9b09cd31158c 100644 --- a/drivers/pci/access.c +++ b/drivers/pci/access.c @@ -700,7 +700,8 @@ static bool pcie_downstream_port(const struct pci_dev *dev) int type = pci_pcie_type(dev); return type == PCI_EXP_TYPE_ROOT_PORT || - type == PCI_EXP_TYPE_DOWNSTREAM; + type == PCI_EXP_TYPE_DOWNSTREAM || + type == PCI_EXP_TYPE_PCIE_BRIDGE; } bool pcie_cap_has_lnkctl(const struct pci_dev *dev) |