diff options
| author | Fabian Imhof <fabian.imhof@ost.ch> | 2025-04-05 15:27:20 +0000 |
|---|---|---|
| committer | Fabian Imhof <fabian.imhof@ost.ch> | 2025-04-05 15:27:20 +0000 |
| commit | a8852f91967a7e55e62e30f5cc07d076092b8b78 (patch) | |
| tree | 12708befd57fc0b89dbadc2e856c935b71c88807 /arch/x86_64/src/kernel/cpu/ss.cpp | |
| parent | c01d080bdc6bd843e840e4834424fe587286b274 (diff) | |
| download | teachos-a8852f91967a7e55e62e30f5cc07d076092b8b78.tar.xz teachos-a8852f91967a7e55e62e30f5cc07d076092b8b78.zip | |
add wip context switch to user mode
Diffstat (limited to 'arch/x86_64/src/kernel/cpu/ss.cpp')
| -rw-r--r-- | arch/x86_64/src/kernel/cpu/ss.cpp | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/arch/x86_64/src/kernel/cpu/ss.cpp b/arch/x86_64/src/kernel/cpu/ss.cpp deleted file mode 100644 index 0978eca..0000000 --- a/arch/x86_64/src/kernel/cpu/ss.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include "arch/kernel/cpu/ss.hpp" - -namespace teachos::arch::kernel::cpu -{ - auto read_ss() -> context_switching::interrupt_descriptor_table::segment_selector - { - context_switching::interrupt_descriptor_table::segment_selector segment_selector{}; - asm volatile("mov %%ss, %[output]" : [output] "=m"(segment_selector)); - return segment_selector; - } - - auto write_ss(context_switching::interrupt_descriptor_table::segment_selector selector) -> void - { - asm volatile("mov %[input], %%ss" : /* no output from call */ : [input] "m"(selector)); - } -} // namespace teachos::arch::kernel::cpu |
