diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2012-08-24 02:36:10 +0200 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2012-08-24 02:36:10 +0200 |
commit | 7bf79d8a9904ee1ed354e7e655f8045afda67fd6 (patch) | |
tree | fde1ddd5e0743b9585bef508ff0baf7a8d90288f /drivers/pci/search.c | |
parent | Merge branch 'pci/bjorn-find-next-ext-cap' into next (diff) | |
parent | PCI: Remove unused pci_dev_b() (diff) | |
download | linux-7bf79d8a9904ee1ed354e7e655f8045afda67fd6.tar.xz linux-7bf79d8a9904ee1ed354e7e655f8045afda67fd6.zip |
Merge branch 'pci/bjorn-cleanup-remove' into next
* pci/bjorn-cleanup-remove:
PCI: Remove unused pci_dev_b()
sgi-agp: Use list_for_each_entry() for bus->devices traversal
parisc/PCI: Use list_for_each_entry() for bus->devices traversal
parisc/PCI: Enable PERR/SERR on all devices
frv/PCI: Use list_for_each_entry() for bus->devices traversal
PCI: Leave normal LIST_POISON in deleted list entries
PCI: Rename local variables to conventional names
PCI: Remove unused, commented-out, code
PCI: Stop and remove devices in one pass
PCI: Fold stop and remove helpers into their callers
PCI: Use list_for_each_entry() for bus->devices traversal
PCI: Remove pci_stop_and_remove_behind_bridge()
PCI: Don't export stop_bus_device and remove_bus_device interfaces
pcmcia: Use common pci_stop_and_remove_bus_device()
PCI: acpiphp: Use common pci_stop_and_remove_bus_device()
PCI: acpiphp: Stop disabling bridges on remove
Diffstat (limited to 'drivers/pci/search.c')
-rw-r--r-- | drivers/pci/search.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/pci/search.c b/drivers/pci/search.c index 621b162ceb69..d84cdcfaacf3 100644 --- a/drivers/pci/search.c +++ b/drivers/pci/search.c @@ -130,16 +130,14 @@ pci_find_next_bus(const struct pci_bus *from) * decrement the reference count by calling pci_dev_put(). * If no device is found, %NULL is returned. */ -struct pci_dev * pci_get_slot(struct pci_bus *bus, unsigned int devfn) +struct pci_dev *pci_get_slot(struct pci_bus *bus, unsigned int devfn) { - struct list_head *tmp; struct pci_dev *dev; WARN_ON(in_interrupt()); down_read(&pci_bus_sem); - list_for_each(tmp, &bus->devices) { - dev = pci_dev_b(tmp); + list_for_each_entry(dev, &bus->devices, bus_list) { if (dev->devfn == devfn) goto out; } |