wip: enable vbe

This commit is contained in:
2024-12-03 10:41:39 +01:00
parent 4bd4198293
commit fb1a1bc213
4 changed files with 19 additions and 96 deletions

View File

@ -1,27 +1,17 @@
# Declare constants for the multiboot header.
.set ALIGN, 1<<0 # align loaded modules on page boundaries
.set MEMINFO, 1<<1 # provide memory map
.set MAGIC, 0xE85250D6 # 'magic number' lets bootloader find the header
.set ARCHITECTURE, 0
.set ALIGN, 1<<0 # align loaded modules on page boundaries
.set MEMINFO, 1<<1 # provide memory map
.set VIDEOMODE, 1<<2 # provide memory map
.set FLAGS, ALIGN | MEMINFO | VIDEOMODE # this is the Multiboot 'flag' field
.set MAGIC, 0x1BADB002 # 'magic number' lets bootloader find the header
.set CHECKSUM, -(MAGIC + FLAGS) # checksum of above, to prove we are multiboot
# Declare a multiboot header that marks the program as a kernel.
.section .multiboot.data, "aw"
header_start:
# HEADER
.long MAGIC
.long ARCHITECTURE
.long header_end - header_start
.long 0x100000000 - (MAGIC + (header_end - header_start))
#TAGS:
# END TAG
.align 8
.int 0 # type
.int 0 # flag
.long 8 # size
header_end:
.align 4
.long MAGIC
.long FLAGS
.long CHECKSUM
# Allocate the initial stack.
.section .bootstrap_stack, "aw", @nobits