aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCédric Le Goater <clg@fr.ibm.com>2014-04-24 03:23:38 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2014-04-28 03:36:17 -0400
commit2d9afb369bc069f11a3a8696c4bdf95d4ddf1281 (patch)
tree4b673b16272bd0f4029ed03e3b9394b744a49526
parentf16e9684996188c12e1f460589003e99086ce36e (diff)
powerpc/boot: Add a global entry point for pseries
When entering the boot wrapper in little endian, we will need to fix the endian order using a fixup trampoline like in the kernel. This patch overrides the _zimage_start entry point for this purpose. Signed-off-by: Cédric Le Goater <clg@fr.ibm.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-rw-r--r--arch/powerpc/boot/Makefile5
-rw-r--r--arch/powerpc/boot/pseries-head.S5
-rwxr-xr-xarch/powerpc/boot/wrapper2
3 files changed, 11 insertions, 1 deletions
diff --git a/arch/powerpc/boot/Makefile b/arch/powerpc/boot/Makefile
index a1f8c7f1ec60..bed660ddf48c 100644
--- a/arch/powerpc/boot/Makefile
+++ b/arch/powerpc/boot/Makefile
@@ -99,6 +99,11 @@ src-plat-$(CONFIG_EMBEDDED6xx) += cuboot-pq2.c cuboot-mpc7448hpc2.c \
99src-plat-$(CONFIG_AMIGAONE) += cuboot-amigaone.c 99src-plat-$(CONFIG_AMIGAONE) += cuboot-amigaone.c
100src-plat-$(CONFIG_PPC_PS3) += ps3-head.S ps3-hvcall.S ps3.c 100src-plat-$(CONFIG_PPC_PS3) += ps3-head.S ps3-hvcall.S ps3.c
101src-plat-$(CONFIG_EPAPR_BOOT) += epapr.c epapr-wrapper.c 101src-plat-$(CONFIG_EPAPR_BOOT) += epapr.c epapr-wrapper.c
102src-plat-$(CONFIG_PPC_PSERIES) += pseries-head.S
103src-plat-$(CONFIG_PPC_POWERNV) += pseries-head.S
104src-plat-$(CONFIG_PPC_IBM_CELL_BLADE) += pseries-head.S
105src-plat-$(CONFIG_PPC_CELLEB) += pseries-head.S
106src-plat-$(CONFIG_PPC_CELL_QPACE) += pseries-head.S
102 107
103src-wlib := $(sort $(src-wlib-y)) 108src-wlib := $(sort $(src-wlib-y))
104src-plat := $(sort $(src-plat-y)) 109src-plat := $(sort $(src-plat-y))
diff --git a/arch/powerpc/boot/pseries-head.S b/arch/powerpc/boot/pseries-head.S
new file mode 100644
index 000000000000..655c3d2c321b
--- /dev/null
+++ b/arch/powerpc/boot/pseries-head.S
@@ -0,0 +1,5 @@
1 .text
2
3 .globl _zimage_start
4_zimage_start:
5 b _zimage_start_lib
diff --git a/arch/powerpc/boot/wrapper b/arch/powerpc/boot/wrapper
index d27a25518b01..5889c440a66a 100755
--- a/arch/powerpc/boot/wrapper
+++ b/arch/powerpc/boot/wrapper
@@ -152,7 +152,7 @@ of)
152 make_space=n 152 make_space=n
153 ;; 153 ;;
154pseries) 154pseries)
155 platformo="$object/of.o $object/epapr.o" 155 platformo="$object/pseries-head.o $object/of.o $object/epapr.o"
156 link_address='0x4000000' 156 link_address='0x4000000'
157 make_space=n 157 make_space=n
158 ;; 158 ;;