summaryrefslogtreecommitdiffstats
path: root/arch/x86_64/loadgdt.S
diff options
context:
space:
mode:
authorJon Santmyer <jon@jonsantmyer.com>2024-03-13 09:58:22 -0400
committerJon Santmyer <jon@jonsantmyer.com>2024-03-13 09:58:22 -0400
commitf46ab8ca2050ee77edf6e6b979875426bdaf29dc (patch)
tree1877f76c37adc4c7f7ea98a24f2cd1a61432ac63 /arch/x86_64/loadgdt.S
parentd1ff7bcc91886626dc9060ec5fb67ee102ab7c1d (diff)
downloadjove-kernel-f46ab8ca2050ee77edf6e6b979875426bdaf29dc.tar.gz
jove-kernel-f46ab8ca2050ee77edf6e6b979875426bdaf29dc.tar.bz2
jove-kernel-f46ab8ca2050ee77edf6e6b979875426bdaf29dc.zip
fix incorrect tss rsp assignment
Diffstat (limited to 'arch/x86_64/loadgdt.S')
-rw-r--r--arch/x86_64/loadgdt.S4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/x86_64/loadgdt.S b/arch/x86_64/loadgdt.S
index e183850..a293bae 100644
--- a/arch/x86_64/loadgdt.S
+++ b/arch/x86_64/loadgdt.S
@@ -6,7 +6,7 @@ x86_64_lgdt:
pushq $0x8
leaq .reload_cs, %rax
pushq %rax
- retfq
+ lretq
.reload_cs:
movw $0x10, %ax
movw %ax, %ds
@@ -15,6 +15,7 @@ x86_64_lgdt:
movw %ax, %gs
movw %ax, %ss
retq
+.size x86_64_lgdt, . - x86_64_lgdt
.global x86_64_flush_tss
.type x86_64_flush_tss @function
@@ -22,3 +23,4 @@ x86_64_flush_tss:
movw $0x30, %ax
ltr %ax
retq
+.size x86_64_flush_tss, . - x86_64_flush_tss