diff options
Diffstat (limited to 'bootasm.S')
-rw-r--r-- | bootasm.S | 8 |
1 files changed, 3 insertions, 5 deletions
@@ -1,15 +1,12 @@ #include "asm.h" +#include "memlayout.h" +#include "mmu.h" # Start the first CPU: switch to 32-bit protected mode, jump into C. # The BIOS loads this code from the first sector of the hard disk into # memory at physical address 0x7c00 and starts executing in real mode # with %cs=0 %ip=7c00. -#define SEG_KCODE 1 // kernel code -#define SEG_KDATA 2 // kernel data+stack - -#define CR0_PE 1 // protected mode enable bit - .code16 # Assemble for 16-bit mode .globl start start: @@ -88,3 +85,4 @@ gdt: gdtdesc: .word (gdtdesc - gdt - 1) # sizeof(gdt) - 1 .long gdt # address gdt + |