[Skiboot] [PATCH 02/11] Make skiboot able to be 2MB rather than 1MB

Stewart Smith stewart at linux.vnet.ibm.com
Thu May 7 17:11:41 AEST 2015


When built with gcov, skiboot is >1MB (closer to 1.5MB) and there
were a few assumptions about skiboot being <1MB.

The biggest one was that when code got larger, we'd have the sbss section
start in the middle of code, so that when we were going to relocate ourselves,
we'd only get the first 1MB of skiboot relocated, which excluded the
_DYNAMIC section, meaning that relocate() would not find the right
sections.

We also needed to not start writing over random parts of skiboot.

Signed-off-by: Stewart Smith <stewart at linux.vnet.ibm.com>
---
 include/mem-map.h |    4 ++--
 skiboot.lds.S     |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/include/mem-map.h b/include/mem-map.h
index 5ed45de..2a903d1 100644
--- a/include/mem-map.h
+++ b/include/mem-map.h
@@ -66,8 +66,8 @@
  * As of this writing (2014/4/6), we use approc 512K for skiboot
  * core and 2M of heap on a 1 socket machine.
  */
-#define HEAP_BASE		(SKIBOOT_BASE + 0x00200000)
-#define HEAP_SIZE		0x00c00000
+#define HEAP_BASE		(SKIBOOT_BASE + 0x00300000)
+#define HEAP_SIZE		0x00b00000
 
 /* This is our PSI TCE table. It's 16K entries on P7 and 256K
  * entries on P8
diff --git a/skiboot.lds.S b/skiboot.lds.S
index a54ff5f..bdc2c2c 100644
--- a/skiboot.lds.S
+++ b/skiboot.lds.S
@@ -133,8 +133,8 @@ SECTIONS
 		KEEP(*(.sym_map))
 	}
 
-	/* We locate the BSS at 1M to leave room for the symbol map */
-	. = 0x100000;
+	/* We locate the BSS at 2M to leave room for the symbol map */
+	. = 0x200000;
 
 	_sbss = .;
 	.bss : {
-- 
1.7.10.4



More information about the Skiboot mailing list