[PATCH 4/4] Use of_find_node_with_property() in pmac_setup_arch()
Benjamin Herrenschmidt
benh at kernel.crashing.org
Thu Nov 13 20:27:25 EST 2008
On Thu, 2008-11-13 at 15:20 +1100, Michael Ellerman wrote:
> Signed-off-by: Michael Ellerman <michael at ellerman.id.au>
Acked-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
---
> ---
> arch/powerpc/platforms/powermac/setup.c | 4 +---
> 1 files changed, 1 insertions(+), 3 deletions(-)
>
> diff --git a/arch/powerpc/platforms/powermac/setup.c b/arch/powerpc/platforms/powermac/setup.c
> index 82c14d2..1293772 100644
> --- a/arch/powerpc/platforms/powermac/setup.c
> +++ b/arch/powerpc/platforms/powermac/setup.c
> @@ -310,9 +310,7 @@ static void __init pmac_setup_arch(void)
> }
>
> /* See if newworld or oldworld */
> - for (ic = NULL; (ic = of_find_all_nodes(ic)) != NULL; )
> - if (of_get_property(ic, "interrupt-controller", NULL))
> - break;
> + ic = of_find_node_with_property(NULL, "interrupt-controller");
> if (ic) {
> pmac_newworld = 1;
> of_node_put(ic);
More information about the Linuxppc-dev
mailing list