summaryrefslogtreecommitdiff
path: root/drivers/pci/pcie/aer
diff options
context:
space:
mode:
authorJohannes Thumshirn <jthumshirn@suse.de>2016-11-03 01:35:51 +0300
committerBjorn Helgaas <bhelgaas@google.com>2016-11-24 01:23:23 +0300
commite784930bd645e7df78c66e7872fec282b0620075 (patch)
treeaacbaa3ec79f78793b60c719291fdcfe55a3ac3d /drivers/pci/pcie/aer
parent9f46107b8ce4f9a4bd6be50e2967df506d1c1631 (diff)
downloadlinux-e784930bd645e7df78c66e7872fec282b0620075.tar.xz
PCI: Export pcie_find_root_port
Export pcie_find_root_port() so we can use it outside of PCIe-AER error injection. Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/pcie/aer')
-rw-r--r--drivers/pci/pcie/aer/aer_inject.c14
1 files changed, 0 insertions, 14 deletions
diff --git a/drivers/pci/pcie/aer/aer_inject.c b/drivers/pci/pcie/aer/aer_inject.c
index db553dc22c8e..2b6a59266689 100644
--- a/drivers/pci/pcie/aer/aer_inject.c
+++ b/drivers/pci/pcie/aer/aer_inject.c
@@ -307,20 +307,6 @@ out:
return 0;
}
-static struct pci_dev *pcie_find_root_port(struct pci_dev *dev)
-{
- while (1) {
- if (!pci_is_pcie(dev))
- break;
- if (pci_pcie_type(dev) == PCI_EXP_TYPE_ROOT_PORT)
- return dev;
- if (!dev->bus->self)
- break;
- dev = dev->bus->self;
- }
- return NULL;
-}
-
static int find_aer_device_iter(struct device *device, void *data)
{
struct pcie_device **result = data;