diff options
author | Cédric Le Goater <clg@fr.ibm.com> | 2014-04-24 09:23:31 +0200 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2014-04-28 17:35:47 +1000 |
commit | 6413010936bac13a965792fa0d0140bdd3b85f3c (patch) | |
tree | 4e65f9a37dcf19a08e62ba9a0efb8b93f600615e /arch/powerpc/boot/oflib.c | |
parent | 034e55e6c2f8e2a9ea37901ea87bac8a08464441 (diff) |
powerpc/boot: Define typedef ihandle as u32
This makes ihandle 64bit friendly.
Signed-off-by: Cédric Le Goater <clg@fr.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/boot/oflib.c')
-rw-r--r-- | arch/powerpc/boot/oflib.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/powerpc/boot/oflib.c b/arch/powerpc/boot/oflib.c index 329437d0e943..956443fb9f65 100644 --- a/arch/powerpc/boot/oflib.c +++ b/arch/powerpc/boot/oflib.c @@ -106,7 +106,7 @@ static int string_match(const char *s1, const char *s2) */ static int need_map = -1; static ihandle chosen_mmu; -static phandle memory; +static ihandle memory; static int check_of_version(void) { @@ -135,10 +135,10 @@ static int check_of_version(void) printf("no mmu\n"); return 0; } - memory = (ihandle) of_call_prom("open", 1, 1, "/memory"); - if (memory == (ihandle) -1) { - memory = (ihandle) of_call_prom("open", 1, 1, "/memory@0"); - if (memory == (ihandle) -1) { + memory = of_call_prom("open", 1, 1, "/memory"); + if (memory == PROM_ERROR) { + memory = of_call_prom("open", 1, 1, "/memory@0"); + if (memory == PROM_ERROR) { printf("no memory node\n"); return 0; } |