diff options
author | Marek Vasut <marex@denx.de> | 2014-03-19 02:21:35 +0100 |
---|---|---|
committer | Stefano Babic <sbabic@denx.de> | 2014-04-01 10:23:01 +0200 |
commit | 65ed5e85723e6e39312d287d9fc6c8f3cbd4f1af (patch) | |
tree | aa1a23c3c5674af4c587abbaa98bc5f8291c2403 /arch/arm | |
parent | 97334c66169af70b665e4726730eadd002cc54b8 (diff) | |
download | u-boot-imx-65ed5e85723e6e39312d287d9fc6c8f3cbd4f1af.zip u-boot-imx-65ed5e85723e6e39312d287d9fc6c8f3cbd4f1af.tar.gz u-boot-imx-65ed5e85723e6e39312d287d9fc6c8f3cbd4f1af.tar.bz2 |
arm: mxs: Properly set GD pointer in SPL
Set the GD pointer in the SPL to a defined symbol so various
functions from U-Boot can be used without adverse side effects.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/cpu/arm926ejs/mxs/spl_boot.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/arm/cpu/arm926ejs/mxs/spl_boot.c b/arch/arm/cpu/arm926ejs/mxs/spl_boot.c index 38109c5..b647e8a 100644 --- a/arch/arm/cpu/arm926ejs/mxs/spl_boot.c +++ b/arch/arm/cpu/arm926ejs/mxs/spl_boot.c @@ -13,9 +13,13 @@ #include <asm/arch/imx-regs.h> #include <asm/arch/sys_proto.h> #include <asm/gpio.h> +#include <linux/compiler.h> #include "mxs_init.h" +DECLARE_GLOBAL_DATA_PTR; +gd_t gdata __section(".data"); + /* * This delay function is intended to be used only in early stage of boot, where * clock are not set up yet. The timer used here is reset on every boot and @@ -121,6 +125,7 @@ void mxs_common_spl_init(const uint32_t arg, const uint32_t *resptr, struct mxs_spl_data *data = (struct mxs_spl_data *) ((CONFIG_SYS_TEXT_BASE - sizeof(struct mxs_spl_data)) & ~0xf); uint8_t bootmode = mxs_get_bootmode_index(); + gd = &gdata; mxs_spl_fixup_vectors(); |