Setup stack bottom
This commit is contained in:
parent
05c78e5e0c
commit
a9c01aefda
2
boot.asm
2
boot.asm
@ -1,3 +1,4 @@
|
||||
; c.f. https://www.gnu.org/software/grub/manual/multiboot/multiboot.html#OS-image-format
|
||||
; Declare constants for the multiboot header.
|
||||
MBALIGN equ 1 << 0 ; align loaded modules on page boundaries
|
||||
MEMINFO equ 1 << 1 ; provide memory map
|
||||
@ -54,6 +55,7 @@ _start:
|
||||
; stack (as it grows downwards on x86 systems). This is necessarily done
|
||||
; in assembly as languages such as C cannot function without a stack.
|
||||
mov esp, stack_top
|
||||
mov ebp, stack_bottom
|
||||
|
||||
; This is a good place to initialize crucial processor state before the
|
||||
; high-level kernel is entered. It's best to minimize the early
|
||||
|
Loading…
Reference in New Issue
Block a user