diff options
Diffstat (limited to 'arch/powerpc/kernel/pci_64.c')
-rw-r--r-- | arch/powerpc/kernel/pci_64.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/powerpc/kernel/pci_64.c b/arch/powerpc/kernel/pci_64.c index 5949bbabd7fb..1930f393d01c 100644 --- a/arch/powerpc/kernel/pci_64.c +++ b/arch/powerpc/kernel/pci_64.c | |||
@@ -227,7 +227,7 @@ EXPORT_SYMBOL(of_create_pci_dev); | |||
227 | void __devinit of_scan_bus(struct device_node *node, | 227 | void __devinit of_scan_bus(struct device_node *node, |
228 | struct pci_bus *bus) | 228 | struct pci_bus *bus) |
229 | { | 229 | { |
230 | struct device_node *child = NULL; | 230 | struct device_node *child; |
231 | const u32 *reg; | 231 | const u32 *reg; |
232 | int reglen, devfn; | 232 | int reglen, devfn; |
233 | struct pci_dev *dev; | 233 | struct pci_dev *dev; |
@@ -235,7 +235,7 @@ void __devinit of_scan_bus(struct device_node *node, | |||
235 | DBG("of_scan_bus(%s) bus no %d... \n", node->full_name, bus->number); | 235 | DBG("of_scan_bus(%s) bus no %d... \n", node->full_name, bus->number); |
236 | 236 | ||
237 | /* Scan direct children */ | 237 | /* Scan direct children */ |
238 | while ((child = of_get_next_child(node, child)) != NULL) { | 238 | for_each_child_of_node(node, child) { |
239 | DBG(" * %s\n", child->full_name); | 239 | DBG(" * %s\n", child->full_name); |
240 | reg = of_get_property(child, "reg", ®len); | 240 | reg = of_get_property(child, "reg", ®len); |
241 | if (reg == NULL || reglen < 20) | 241 | if (reg == NULL || reglen < 20) |