FENIX_kernel/arch/i386/pmode.S
2021-01-10 14:43:23 -06:00

21 lines
No EOL
295 B
ArmAsm

.globl enter_pmode
.type enter_pmode,%function
enter_pmode:
.func enter_pmode
cli
mov %cr0, %eax
or $1, %eax
mov %eax, %cr0
ljmp $0x8, $pmode
.code32
pmode:
mov $0x10, %ax
mov %ax, %ds
mov %ax, %ss
mov %ax, %es
mov %ax, %fs
mov %ax, %gs
mov $0x90000, %esp
lret