summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorFabio Estevam <festevam@gmail.com>2011-12-29 03:35:38 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-01-16 08:40:09 +0100
commit1084606c972ea5f1d89f69bdbd978b867d0ee521 (patch)
treeffb941003c652304fc9bb5bfbb3f51309678019b /include
parentd109ed946c29a29e840654afa0832567408dde51 (diff)
m28evk: Use GENERATED_GBL_DATA_SIZE
Use GENERATED_GBL_DATA_SIZE for calculating CONFIG_SYS_INIT_SP_OFFSET. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Diffstat (limited to 'include')
-rw-r--r--include/configs/m28evk.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/include/configs/m28evk.h b/include/configs/m28evk.h
index 39c841f44c..2b4871e1f9 100644
--- a/include/configs/m28evk.h
+++ b/include/configs/m28evk.h
@@ -92,7 +92,14 @@
#define CONFIG_SYS_MEMTEST_END 0x40400000 /* 4 MB RAM test */
#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1
/* Point initial SP in SRAM so SPL can use it too. */
-#define CONFIG_SYS_INIT_SP_ADDR 0x00002000
+
+#define CONFIG_SYS_INIT_RAM_ADDR 0x00002000
+#define CONFIG_SYS_INIT_RAM_SIZE (128 * 1024)
+
+#define CONFIG_SYS_INIT_SP_OFFSET \
+ (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
+#define CONFIG_SYS_INIT_SP_ADDR \
+ (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
/*
* We need to sacrifice first 4 bytes of RAM here to avoid triggering some
* strange BUG in ROM corrupting first 4 bytes of RAM when loading U-Boot