BarryServer : Git

All the code for all my projects
// BarryServer : Git / Nucleus / commit / d46e09a34ca8cd546f3a4312976cf3b6a5a55ccf / task / syscall.c

// Related

Nucleus

Barry Improved context switching and interrupt handling d46e09a (3 years, 2 months ago)
diff --git a/task/syscall.c b/task/syscall.c
index e0b2d23..8e33ef4 100644
--- a/task/syscall.c
+++ b/task/syscall.c
@@ -87,9 +87,11 @@ struct SyscallEntry syscalls[] = {
 };
 
 /* Handle a syscall */
-int
-syscall_handler(int num, uintptr_t args)
+void
+syscall_handler(struct InterruptFrame *frame)
 {
+	int num = frame->eax;
+	uintptr_t args = frame->esi;
 	int ret = -EINVAL;
 	enter_syscall_context(num);
 
@@ -115,5 +117,5 @@ syscall_handler(int num, uintptr_t args)
 
 end:
 	exit_syscall_context();
-	return ret;
+	frame->eax = ret;
 }