aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2009-06-02 16:56:57 -0700
committerH. Peter Anvin <hpa@zytor.com>2009-06-02 16:58:26 -0700
commitc0e6f47b3219e27ba23a1bc4d19696e6d19d1682 (patch)
treec0255ff53c828eb5620071fde4faa9b7d494ad52
parentbe65e736d7ce7b1961bab7000eb7789c8ba35ef3 (diff)
downloadsyslinux-c0e6f47b3219e27ba23a1bc4d19696e6d19d1682.tar.gz
syslinux-c0e6f47b3219e27ba23a1bc4d19696e6d19d1682.tar.xz
syslinux-c0e6f47b3219e27ba23a1bc4d19696e6d19d1682.zip
core: handle section aliases in ld script; increase STACK32_LEN
Handle aliases that gcc generates in the ld script. Increase STACK32_LEN to something a little more reasonable. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r--core/layout.inc2
-rw-r--r--core/syslinux.ld15
2 files changed, 12 insertions, 5 deletions
diff --git a/core/layout.inc b/core/layout.inc
index 72236839..ded0bf31 100644
--- a/core/layout.inc
+++ b/core/layout.inc
@@ -81,7 +81,7 @@ RBFG_brainfuck: resb 2048 ; Bigger than an Ethernet packet...
SECINFO pm_code
SECINFO high_clear
- extern __bss_start, __bss_end, __bss_len, __bss_dwords
+ SECINFO bss
extern free_high_memory
diff --git a/core/syslinux.ld b/core/syslinux.ld
index b931ed2e..44d3b548 100644
--- a/core/syslinux.ld
+++ b/core/syslinux.ld
@@ -20,8 +20,8 @@ OUTPUT_ARCH(i386)
EXTERN(_start)
ENTRY(_start)
-STACK16_LEN = 4096;
-STACK32_LEN = 8192;
+STACK16_LEN = 4096;
+STACK32_LEN = 32768;
SECTIONS
{
@@ -219,6 +219,7 @@ SECTIONS
FILL(0x90909090)
__text_start = .;
*(.text)
+ *(.text.*)
__text_end = .;
}
@@ -229,6 +230,7 @@ SECTIONS
.rodata : AT(__rodata_lma) {
__rodata_start = .;
*(.rodata)
+ *(.rodata.*)
__rodata_end = .;
}
@@ -250,6 +252,7 @@ SECTIONS
.data : AT(__data_lma) {
__data_start = .;
*(.data)
+ *(.data.*)
__data_end = .;
}
@@ -260,9 +263,12 @@ SECTIONS
. = ALIGN(128);
__bss_vma = .;
- .bss : AT (__bss_vma) {
+ __bss_lma = .; /* Dummy */
+ .bss (NOLOAD) : AT (__bss_lma) {
__bss_start = .;
*(.bss)
+ *(.bss.*)
+ *(COMMON)
__bss_end = .;
}
__bss_len = __bss_end - __bss_start;
@@ -272,7 +278,8 @@ SECTIONS
/* XXX: This stack should be unified with the COM32 stack */
__stack_vma = .;
- .stack : AT(__stack_vma) {
+ __stack_lma = .; /* Dummy */
+ .stack (NOLOAD) : AT(__stack_lma) {
__stack_start = .;
. += STACK32_LEN;
__stack_end = .;