This repository has been archived on 2025-02-26. You can view files and clone it, but cannot push or open issues or pull requests.
hilbert-os/kernel/paging.asm
2024-01-08 22:28:41 -05:00

16 lines
248 B
NASM

bits 64
;see also ../documentation/memory.txt
global switch_to_kernel_p4
;from paging.cpp:
extern __kernel_p4_paddr
section .text
switch_to_kernel_p4:
mov rax, qword [__kernel_p4_paddr]
mov cr3, rax
mov rsp, 0xfffffffffffff000
jmp rdi