summaryrefslogtreecommitdiff
path: root/core/syslinux.ld
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2010-02-24 11:14:04 -0800
committerH. Peter Anvin <hpa@zytor.com>2010-02-24 11:14:04 -0800
commita2656772d030444ee1e2bdd289d3726edcf2d741 (patch)
treeae95480e57bdf09238cadb873f5d773f2dfee926 /core/syslinux.ld
parente0e20f0ab948e372444c748ffbef65a30aafe4f8 (diff)
downloadsyslinux-a2656772d030444ee1e2bdd289d3726edcf2d741.tar.gz
core: move aligned segments earlier
Move the aligned segments downward, to provide for the largest possible contiguous lowmem heap. This minimizes the necessary lowmem footprint. (Note: the heap doesn't actually need to be contiguous, but having it not be makes it harder to size.) Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'core/syslinux.ld')
-rw-r--r--core/syslinux.ld35
1 files changed, 18 insertions, 17 deletions
diff --git a/core/syslinux.ld b/core/syslinux.ld
index 6c7cd974..fd5c5fe6 100644
--- a/core/syslinux.ld
+++ b/core/syslinux.ld
@@ -196,8 +196,24 @@ SECTIONS
__assert_end16 = ASSERT(_end16 <= 0x10000, "64K overflow");
/*
- * The auxilliary data segment is allowed to spill out of the
- * low 64K.
+ * Special 16-bit segments
+ */
+
+ . = ALIGN(65536);
+ .real_mode (NOLOAD) : {
+ *(.real_mode)
+ }
+ real_mode_seg = core_real_mode >> 4;
+
+ . = ALIGN(65536);
+ .xfer_buf (NOLOAD) : {
+ *(.xfer_buf)
+ }
+ xfer_buf_seg = core_xfer_buf >> 4;
+
+ /*
+ * The auxilliary data segment is used by the 16-bit code
+ * for items that don't need to live in the bottom 64K.
*/
. = ALIGN(16);
@@ -226,21 +242,6 @@ SECTIONS
__high_clear_len = __high_clear_end - __high_clear_start;
__high_clear_dwords = (__high_clear_len + 3) >> 2;
- /*
- * Special 16-bit segments
- */
- . = ALIGN(65536);
- .real_mode (NOLOAD) : {
- *(.real_mode)
- }
- real_mode_seg = core_real_mode >> 4;
-
- . = ALIGN(65536);
- .xfer_buf (NOLOAD) : {
- *(.xfer_buf)
- }
- xfer_buf_seg = core_xfer_buf >> 4;
-
/* Start of the lowmem heap */
__lowmem_heap = .;