summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/boot/oflib.c
diff options
context:
space:
mode:
authorCédric Le Goater <clg@fr.ibm.com>2014-04-24 09:23:36 +0200
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2014-04-28 17:36:08 +1000
commit93d3921042988317e94b1bcc2e19844efe0b7356 (patch)
tree66cf4989366fe198c1394d24f1f912e39ef0df31 /arch/powerpc/boot/oflib.c
parent002c39dba3fc47b953101790d798f69150366738 (diff)
downloadtalos-op-linux-93d3921042988317e94b1bcc2e19844efe0b7356.tar.gz
talos-op-linux-93d3921042988317e94b1bcc2e19844efe0b7356.zip
powerpc/boot: Define a routine to enter prom
This patch defines a 'prom' routine similar to 'enter_prom' in the kernel. The difference is in the MSR which is built before entering prom. Big endian order is enforced as in the kernel but 32bit mode is not. It prepares ground for the next patches which will introduce Little endian order. 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.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/powerpc/boot/oflib.c b/arch/powerpc/boot/oflib.c
index cdfe762d2b2b..46c98a47d949 100644
--- a/arch/powerpc/boot/oflib.c
+++ b/arch/powerpc/boot/oflib.c
@@ -27,11 +27,17 @@ struct prom_args {
__be32 args[10]; /* Input/output arguments. */
};
+#ifdef __powerpc64__
+extern int prom(void *);
+#else
static int (*prom) (void *);
+#endif
void of_init(void *promptr)
{
+#ifndef __powerpc64__
prom = (int (*)(void *))promptr;
+#endif
}
#define ADDR(x) (u32)(unsigned long)(x)
OpenPOWER on IntegriCloud