summaryrefslogtreecommitdiff
path: root/src/kernel/arch/amd64/boot64.s
diff options
context:
space:
mode:
authordzwdz2024-07-25 20:15:40 +0200
committerdzwdz2024-07-25 20:15:40 +0200
commit24934406d5d39e013e22a9e6f4138c4169460d71 (patch)
tree358f6c1dc386c50b85900a557321a256048737cd /src/kernel/arch/amd64/boot64.s
parenta6fabfb78e70b8096a8bf336aa64a3358a2f5eca (diff)
kernel: set up the GDT in assembly
This is just for simplicity's sake. I think I could even omit the `movw $TSS, (GdtTss + 2)` and have the linker fill that out as a relocation, but that would probably be more complex overall.
Diffstat (limited to 'src/kernel/arch/amd64/boot64.s')
-rw-r--r--src/kernel/arch/amd64/boot64.s12
1 files changed, 0 insertions, 12 deletions
diff --git a/src/kernel/arch/amd64/boot64.s b/src/kernel/arch/amd64/boot64.s
deleted file mode 100644
index 9bd9f0c..0000000
--- a/src/kernel/arch/amd64/boot64.s
+++ /dev/null
@@ -1,12 +0,0 @@
-.global boot64
-boot64:
- lgdt (lgdt_arg) // try reloading gdt again
- mov $(6 << 3 | 3), %ax // SEG_TSS
- ltr %ax
-
- push %rdi // preserve multiboot struct
- call sysenter_setup
- pop %rdi
-
- // multiboot struct in %rdi
- jmp kmain_early