[U-Boot] [PATCH v2 2/4] da850evm, da850_am18xxevm: fix CONFIG_SPL_MAX_SIZE semantics

Albert ARIBAUD albert.u.boot at aribaud.net
Wed Apr 10 01:14:53 CEST 2013


CONFIG_SPL_MAX_SIZE wrongly included BSS size.
Split 32K max size between 24K image (text,rodata,data)
and 8K BSS based on sizes reported for current build:

   text	   data	    bss
  15676	   1316	    108

Signed-off-by: Albert ARIBAUD <albert.u.boot at aribaud.net>
---
Changes in v2:
- fixed commit summary typoes

 board/davinci/da8xxevm/u-boot-spl-da850evm.lds |    2 +-
 include/configs/da850evm.h                     |    4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/board/davinci/da8xxevm/u-boot-spl-da850evm.lds b/board/davinci/da8xxevm/u-boot-spl-da850evm.lds
index bc34fb5..d7edeb2 100644
--- a/board/davinci/da8xxevm/u-boot-spl-da850evm.lds
+++ b/board/davinci/da8xxevm/u-boot-spl-da850evm.lds
@@ -25,7 +25,7 @@
  */
 
 MEMORY { .sram : ORIGIN = CONFIG_SPL_TEXT_BASE,\
-		LENGTH = CONFIG_SPL_MAX_SIZE }
+		LENGTH = (CONFIG_SPL_MAX_SIZE + CONFIG_SPL_BSS_MAX_SIZE) }
 
 OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
 OUTPUT_ARCH(arm)
diff --git a/include/configs/da850evm.h b/include/configs/da850evm.h
index 99b4de7..e15c86e 100644
--- a/include/configs/da850evm.h
+++ b/include/configs/da850evm.h
@@ -399,7 +399,9 @@
 #define CONFIG_SPL_LDSCRIPT	"board/$(BOARDDIR)/u-boot-spl-da850evm.lds"
 #define CONFIG_SPL_STACK	0x8001ff00
 #define CONFIG_SPL_TEXT_BASE	0x80000000
-#define CONFIG_SPL_MAX_SIZE	32768
+/* SPL max size is 24K -- but --pad-to requires a single decimal number */
+#define CONFIG_SPL_MAX_SIZE	24576
+#define CONFIG_SPL_BSS_MAX_SIZE	(8*1024)
 #endif
 
 /* Load U-Boot Image From MMC */
-- 
1.7.10.4



More information about the U-Boot mailing list