aboutsummaryrefslogtreecommitdiff
path: root/arch/x86_64/src/context_switching
diff options
context:
space:
mode:
authorFabian Imhof <fabian.imhof@ost.ch>2025-03-27 14:02:05 +0000
committerFabian Imhof <fabian.imhof@ost.ch>2025-03-27 14:02:05 +0000
commit9ddfcd02413a93718e8cde53f9ba5a96a5b29b8f (patch)
treea31e132e717c9acc68f2480e9d50d78b32711262 /arch/x86_64/src/context_switching
parenta6c5f6a273d0c5c4161f600fca6d4fe49858c23c (diff)
downloadteachos-9ddfcd02413a93718e8cde53f9ba5a96a5b29b8f.tar.xz
teachos-9ddfcd02413a93718e8cde53f9ba5a96a5b29b8f.zip
update long jump handling
Diffstat (limited to 'arch/x86_64/src/context_switching')
-rw-r--r--arch/x86_64/src/context_switching/main.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/x86_64/src/context_switching/main.cpp b/arch/x86_64/src/context_switching/main.cpp
index c3c0cf0..1417a25 100644
--- a/arch/x86_64/src/context_switching/main.cpp
+++ b/arch/x86_64/src/context_switching/main.cpp
@@ -13,10 +13,8 @@ namespace teachos::arch::context_switching
decltype(auto) global_descriptor_table = segment_descriptor_table::initialize_global_descriptor_table();
decltype(auto) interrupt_descriptor_table = interrupt_descriptor_table::initialize_interrupt_descriptor_table();
- interrupt_descriptor_table::segment_selector segment_selector{
- 1U, interrupt_descriptor_table::segment_selector::REQUEST_LEVEL_KERNEL};
- kernel::cpu::far_pointer pointer{boot::segment_register_reload_pointer, segment_selector};
- kernel::cpu::jmp(pointer);
+ // Execute trampoline function for the GDT loading long jump
+ boot::reload_segment_register_trampoline();
// Load task state segment descriptor from the last element in the global descriptor table, done by calculating
// offset in bytes to the start of the segment descriptor (5 * 16) = 80