Syscalls working as expected

This commit is contained in:
Alex
2022-11-15 15:09:52 +02:00
parent 5dd496a73f
commit c2628019b7
10 changed files with 61 additions and 53 deletions

View File

@ -55,16 +55,10 @@ namespace InterruptDescriptorTable
"pushq %r13\n"
"pushq %r14\n"
"pushq %r15\n"
// push ds segment
"movq %ds, %rax\n"
"pushq %rax\n"
"movq %rsp, %rdi\n"
"call ExceptionHandler\n"
// pop ds segment
"popq %rax\n"
// pop all registers
"popq %r15\n"
"popq %r14\n"
@ -104,16 +98,10 @@ namespace InterruptDescriptorTable
"pushq %r13\n"
"pushq %r14\n"
"pushq %r15\n"
// push ds segment
"movq %ds, %rax\n"
"pushq %rax\n"
"movq %rsp, %rdi\n"
"call MainInterruptHandler\n"
// pop ds segment
"popq %rax\n"
"popq %r15\n"
"popq %r14\n"
"popq %r13\n"