Skip to content

Commit

Permalink
frv/PCI: Use list_for_each_entry() for bus->devices traversal
Browse files Browse the repository at this point in the history
Replace open-coded list traversal with list_for_each_entry().

Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: Yinghai Lu <yinghai@kernel.org>
CC: David Howells <dhowells@redhat.com>
  • Loading branch information
Bjorn Helgaas committed Aug 22, 2012
1 parent a7479d7 commit fd37683
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions arch/frv/mb93090-mb00/pci-vdk.c
Original file line number Diff line number Diff line change
Expand Up @@ -330,10 +330,8 @@ void __init pcibios_fixup_bus(struct pci_bus *bus)
pci_read_bridge_bases(bus);

if (bus->number == 0) {
struct list_head *ln;
struct pci_dev *dev;
for (ln=bus->devices.next; ln != &bus->devices; ln=ln->next) {
dev = pci_dev_b(ln);
list_for_each_entry(dev, &bus->devices, bus_list) {
if (dev->devfn == 0) {
dev->resource[0].start = 0;
dev->resource[0].end = 0;
Expand Down

0 comments on commit fd37683

Please sign in to comment.