diff options
author | Marvin Borner | 2020-04-17 00:39:10 +0200 |
---|---|---|
committer | Marvin Borner | 2020-04-17 00:39:10 +0200 |
commit | 203c6950ab45e89ababa594d5b359118e17bfd02 (patch) | |
tree | b9caeb2f1c7ada9b728191cf3680873472f5cef6 /src/kernel/boot.asm | |
parent | 9ff8deafdff307cbec1ef431c65009ffb8119859 (diff) |
Started implementing multiboot2 standard
Diffstat (limited to 'src/kernel/boot.asm')
-rw-r--r-- | src/kernel/boot.asm | 33 |
1 files changed, 22 insertions, 11 deletions
diff --git a/src/kernel/boot.asm b/src/kernel/boot.asm index 968a824..9086dbd 100644 --- a/src/kernel/boot.asm +++ b/src/kernel/boot.asm @@ -1,14 +1,25 @@ -%define ALIGN 1 ; Align loaded modules on page boundaries -%define MEMINFO 2 ; Provide memory map -%define FLAGS 3 ; Flags (ALIGN | MEMINFO) -%define MAGIC 0x1BADB002 -%define CHECKSUM -(MAGIC + FLAGS) - section .multiboot - align 4 - dd MAGIC - dd FLAGS - dd CHECKSUM + header_start: + dd 0xe85250d6 + dd 0 + dd header_end - header_start + dd 0x100000000 - (0xe85250d6 + 0 + (header_end - header_start)) + mb2_tag_info_start: + dw 1 + dw 0 ; Non-optional + dd mb2_tag_info_end - mb2_tag_info_start + dd 1 + dd 2 + dd 4 + dd 6 + mb2_tag_info_end: + align 8 + mb2_tag_end_start: + dw 0 + dw 0 + dd mb2_tag_end_end - mb2_tag_end_start + mb2_tag_end_end: + header_end: section .start_section dd _start @@ -70,4 +81,4 @@ section .text section .end_section global ASM_KERNEL_END ASM_KERNEL_END: - ; Kernel size detection
\ No newline at end of file + ; Kernel size detection |