summaryrefslogtreecommitdiff
path: root/arch/powerpc/boot/of.c
diff options
context:
space:
mode:
authorCédric Le Goater <clg@fr.ibm.com>2014-04-24 11:23:30 +0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2014-04-28 11:35:43 +0400
commit034e55e6c2f8e2a9ea37901ea87bac8a08464441 (patch)
tree07bf1168a28a1cbc85c9231a16300d05d48b923c /arch/powerpc/boot/of.c
parent9cc36bb0aca622539be59266012d8be4346f0996 (diff)
downloadlinux-034e55e6c2f8e2a9ea37901ea87bac8a08464441.tar.xz
powerpc/boot: Rework of_claim() to make it 64bit friendly
This patch fixes 64bit compile warnings and updates the wrapper code to converge the kernel code in prom_init. 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/of.c')
-rw-r--r--arch/powerpc/boot/of.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/powerpc/boot/of.c b/arch/powerpc/boot/of.c
index 62e2f43ec1df..7ca910cb2fc6 100644
--- a/arch/powerpc/boot/of.c
+++ b/arch/powerpc/boot/of.c
@@ -40,8 +40,8 @@ static void *of_try_claim(unsigned long size)
#ifdef DEBUG
printf(" trying: 0x%08lx\n\r", claim_base);
#endif
- addr = (unsigned long)of_claim(claim_base, size, 0);
- if ((void *)addr != (void *)-1)
+ addr = (unsigned long) of_claim(claim_base, size, 0);
+ if (addr != PROM_ERROR)
break;
}
if (addr == 0)