summaryrefslogtreecommitdiff
path: root/arch/arm/lib/crt0.S
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2014-07-10 22:23:29 -0600
committerSimon Glass <sjg@chromium.org>2014-08-04 05:24:35 -0600
commit76a1e584e10d14f1981f65376636ecff80bdc19b (patch)
tree2e7415090101ac9940e1e23cc3997b9e65ce302f /arch/arm/lib/crt0.S
parentaae2aef9c807a13ec9074efe48fae5bb5e3c6039 (diff)
downloadu-boot-imx-76a1e584e10d14f1981f65376636ecff80bdc19b.zip
u-boot-imx-76a1e584e10d14f1981f65376636ecff80bdc19b.tar.gz
u-boot-imx-76a1e584e10d14f1981f65376636ecff80bdc19b.tar.bz2
arm: Support pre-relocation malloc()
Add support for re-relocation malloc() in arm's start-up code. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/arm/lib/crt0.S')
-rw-r--r--arch/arm/lib/crt0.S5
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/arm/lib/crt0.S b/arch/arm/lib/crt0.S
index 43aa212..29cdad0 100644
--- a/arch/arm/lib/crt0.S
+++ b/arch/arm/lib/crt0.S
@@ -78,7 +78,10 @@ clr_gd:
strlo r0, [r1] /* clear 32-bit GD word */
addlo r1, r1, #4 /* move to next */
blo clr_gd
-
+#if defined(CONFIG_SYS_MALLOC_F_LEN) && !defined(CONFIG_SPL_BUILD)
+ sub sp, sp, #CONFIG_SYS_MALLOC_F_LEN
+ str sp, [r9, #GD_MALLOC_BASE]
+#endif
/* mov r0, #0 not needed due to above code */
bl board_init_f