diff options
Diffstat (limited to 'src/boot/boot.S')
| -rw-r--r-- | src/boot/boot.S | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/boot/boot.S b/src/boot/boot.S index e436cbb..9777fbf 100644 --- a/src/boot/boot.S +++ b/src/boot/boot.S @@ -3,6 +3,8 @@ .extern bringelle .extern gdt_memcpy .extern mb_load_fb_tag +.extern _bss_start +.extern _bss_end .set STACK_LOCATION, 0x1FFFFF @@ -73,6 +75,17 @@ movl $STACK_LOCATION,%esp mov $0x38, %eax ltr %ax +# Zeroing the .bss section +mov $_bss_start, %eax +mov $_bss_end, %ebx +start_zeroing: + movb $0x0, (%eax) + cmp %eax, %ebx + je end_zeroing + inc %eax + jmp start_zeroing +end_zeroing: + # Start kernel main function call bringelle |
