summaryrefslogtreecommitdiff
path: root/linker.ld
diff options
context:
space:
mode:
authordzwdz2021-07-10 18:12:46 +0200
committerdzwdz2021-07-10 18:12:46 +0200
commit49a9de571ad0c604cb569d46d514f25bdc45d8ca (patch)
tree91d0de09529a6d286877451f4909116edd552ba1 /linker.ld
parent1bf5e324005ce7122a195af106cec656960648dc (diff)
allocate the initial stack directly in linker.ld
IMO it's cleaner this way. I wanted to put it just under 1M, but it turns out that it isn't accessible at boot in QEMU.
Diffstat (limited to 'linker.ld')
-rw-r--r--linker.ld4
1 files changed, 4 insertions, 0 deletions
diff --git a/linker.ld b/linker.ld
index be2b44f..92db365 100644
--- a/linker.ld
+++ b/linker.ld
@@ -20,6 +20,10 @@ SECTIONS
{
*(COMMON)
*(.bss)
+
+ stack_bottom = .;
+ . += 16K;
+ stack_top = .;
}
_kernel_end = (. + 0xFFF) & ~0xFFF; /* aligned to 4K */
}