summaryrefslogtreecommitdiff
path: root/src/kernel/arch/i386/sysenter.c
diff options
context:
space:
mode:
authordzwdz2022-04-21 19:13:33 +0200
committerdzwdz2022-04-21 19:13:33 +0200
commita990307680233460b2243c84002725b05a68b94a (patch)
treebf8129c3dc227e7910026d6f3a42efeb2af8a40a /src/kernel/arch/i386/sysenter.c
parent0ae12266b7160272fd95875006c6c1b6d6b1dcd2 (diff)
kernel/proc: only expose `process_switch_any()`
other parts of the kernel don't need to care about which process exactly gets switched into
Diffstat (limited to 'src/kernel/arch/i386/sysenter.c')
-rw-r--r--src/kernel/arch/i386/sysenter.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/kernel/arch/i386/sysenter.c b/src/kernel/arch/i386/sysenter.c
index 5712ee3..1d2a333 100644
--- a/src/kernel/arch/i386/sysenter.c
+++ b/src/kernel/arch/i386/sysenter.c
@@ -23,10 +23,6 @@ _Noreturn void sysenter_stage2(void) {
val = _syscall(regs->eax, regs->ebx,
regs->esi, regs->edi, (uintptr_t)regs->ebp);
- if (process_current->state == PS_RUNNING) { // TODO move to _syscall()
- regs_savereturn(&process_current->regs, val);
- process_switch(process_current); // TODO process_resume
- } else {
- process_switch_any();
- }
+ regs_savereturn(&process_current->regs, val);
+ process_switch_any();
}