Skip to content

Commit

Permalink
powerpc: Use for_each_node_with_property() in of_irq_map_init()
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
  • Loading branch information
Michael Ellerman authored and Paul Mackerras committed Nov 19, 2008
1 parent 1e291b1 commit 5401817
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions arch/powerpc/kernel/prom_parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -731,10 +731,7 @@ void of_irq_map_init(unsigned int flags)
if (flags & OF_IMAP_NO_PHANDLE) {
struct device_node *np;

for(np = NULL; (np = of_find_all_nodes(np)) != NULL;) {
if (of_get_property(np, "interrupt-controller", NULL)
== NULL)
continue;
for_each_node_with_property(np, "interrupt-controller") {
/* Skip /chosen/interrupt-controller */
if (strcmp(np->name, "chosen") == 0)
continue;
Expand Down

0 comments on commit 5401817

Please sign in to comment.