ChangeSet 1.1290, 2003/06/04 17:41:03-07:00, greg@kroah.com [PATCH] PCI: remove usage of pci_for_each_dev() in arch/ppc/platforms/pmac_pci.c arch/ppc/platforms/pmac_pci.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff -Nru a/arch/ppc/platforms/pmac_pci.c b/arch/ppc/platforms/pmac_pci.c --- a/arch/ppc/platforms/pmac_pci.c Wed Jun 4 18:07:19 2003 +++ b/arch/ppc/platforms/pmac_pci.c Wed Jun 4 18:07:19 2003 @@ -494,7 +494,7 @@ static void __init pcibios_fixup_OF_interrupts(void) { - struct pci_dev* dev; + struct pci_dev* dev = NULL; /* * Open Firmware often doesn't initialize the @@ -502,7 +502,7 @@ * should find the device node and apply the interrupt * obtained from the OF device-tree */ - pci_for_each_dev(dev) { + while ((dev = pci_find_device(PCI_ANY_ID, PCI_ANY_ID, dev)) != NULL) { struct device_node *node; node = pci_device_to_OF_node(dev); /* this is the node, see if it has interrupts */ @@ -590,7 +590,7 @@ struct device_node* nd; #ifdef CONFIG_BLK_DEV_IDE - struct pci_dev *dev; + struct pci_dev *dev = NULL; /* OF fails to initialize IDE controllers on macs * (and maybe other machines) @@ -602,7 +602,7 @@ * * -- BenH */ - pci_for_each_dev(dev) { + while ((dev = pci_find_device(PCI_ANY_ID, PCI_ANY_ID, dev)) != NULL) { if ((dev->class >> 16) == PCI_BASE_CLASS_STORAGE) pci_enable_device(dev); }