diff options
author | Gavin Shan <gwshan@linux.vnet.ibm.com> | 2016-06-10 15:03:39 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2016-06-14 16:00:16 +1000 |
commit | 72552138f07fb29dd7f4ceb0831f492e71b060d0 (patch) | |
tree | 282ccf20c07c2f41224c7363514e02ca73c4dc22 /hw/npu.c | |
parent | 306b47d08a7520a08acdbbe06bcb1668eaf4b42c (diff) | |
download | talos-skiboot-72552138f07fb29dd7f4ceb0831f492e71b060d0.tar.gz talos-skiboot-72552138f07fb29dd7f4ceb0831f492e71b060d0.zip |
core/pci: Extend pci_walk_dev() for PCI slot
Currently, pci_walk_dev() iterates all PCI devices behind the
specified PHB. This extends the function to allow iteration
on PCI devices behind the specified PCI slot so that it can
be used by PCI hotplug logic in the subsequent patches.
Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
Reviewed-by: Russell Currey <ruscur@russell.cc>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/npu.c')
-rw-r--r-- | hw/npu.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -541,7 +541,7 @@ static void npu_dev_bind_pci_dev(struct npu_dev *dev) if (!phb) continue; - dev->pd = pci_walk_dev(phb, __npu_dev_bind_pci_dev, dev); + dev->pd = pci_walk_dev(phb, NULL, __npu_dev_bind_pci_dev, dev); if (dev->pd) { dev->phb = phb; /* Found the device, set the bit in config space */ @@ -618,7 +618,7 @@ static int npu_dn_fixup(struct phb *phb, static void npu_phb_final_fixup(struct phb *phb) { - pci_walk_dev(phb, npu_dn_fixup, NULL); + pci_walk_dev(phb, NULL, npu_dn_fixup, NULL); } static void npu_ioda_init(struct npu *p) |