Skip to content

Commit 418c676

Browse files
committed
Set EFER.NXE, since Limine sets up an initial PD with NX bits set
1 parent 18a4902 commit 418c676

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

kernel/src/ap/ap_startup.asm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,10 +84,10 @@ protectedStart:
8484
mov eax, [0x500]
8585
mov cr3, eax
8686

87-
; Set up EFER MSR to enable long mode (EFER.LME)
87+
; Set up EFER.LME & EFER.NXE
8888
mov ecx, 0xC0000080
8989
rdmsr
90-
or eax, 1 << 8
90+
or eax, (1 << 8) | (1 << 11)
9191
wrmsr
9292

9393
; Enable paging

0 commit comments

Comments
 (0)