2. Which base of the GDT?1. Load your kernel in physical memory starting at 1MB. Already done.
2. Have no paging at start-up, but a kernel code and data segment that has a base such as 1MB == 1GB(0x4000.0000)
3. Enable paging mapping logical linear address 0x4000.0000 -> to physical addresses 0x0010.0000 ->
4. Reset the base of kernel code and data segment so that you have a flat_mode kernel.
Code: Select all
FLAT_CODE_SEL equ $-gdt
dw 0xFFFF ; Limit
dw 0 ; Base 15:0
db 0 ; Base 23:16
db 0x9A
db 0xCF
db 0 ; Base 31:24