Skip to contentSkip to conversation

ppc: Allow boards to specify how much memory they can map

PATCH New Kumar Gala 2 participants 2 messages Feb 15, 2008 – Mar 25, 2008

lore
Share & tools
lore

Kumar Gala

author
#0 lore raw

PATCH 1/1 ppc: Allow boards to specify how much memory they can map

For historical reasons we limited the stack to 256M because some boards could only map that much via BATS. However newer boards are capable of mapping more memory (for example 85xx is capble of doing up to 2G).

---
 lib_ppc/board.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
lib_ppc/board.c +6 -1
index 45d1328..8c9f6e6 100644
@@ -419,12 +419,17 @@ void board_init_f (ulong bootflag)
 	 */
 	len = (ulong)&_end - CFG_MONITOR_BASE;
 
+#ifndef CONFIG_MAX_MEM_MAPPED
+#define CONFIG_MAX_MEM_MAPPED (256 << 20)
+#endif
+
 #ifndef	CONFIG_VERY_BIG_RAM
 	addr = CFG_SDRAM_BASE + gd->ram_size;
 #else
 	/* only allow stack below 256M */
 	addr = CFG_SDRAM_BASE +
-	       (gd->ram_size > 256 << 20) ? 256 << 20 : gd->ram_size;
+		(gd->ram_size > CONFIG_MAX_MEM_MAPPED) ?
+		CONFIG_MAX_MEM_MAPPED : gd->ram_size;
 #endif
 
 #ifdef CONFIG_LOGBUFFER
Signature · 1 line
1.5.3.8
#1 lore raw

PATCH 1/1 ppc: Allow boards to specify how much memory they can map

Quoted 8 lines · In message <[email protected]> you wrote:

For historical reasons we limited the stack to 256M because some boards could only map that much via BATS. However newer boards are capable of mapping more memory (for example 85xx is capble of doing up to 2G).

---
 lib_ppc/board.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

Applied, after resoving merge conflicts.

Please check if everythign is OK.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Do not follow where the path may lead....go instead where there is no
path and leave a trail.