diff options
author | Ian Moffett <ian@osmora.org> | 2024-03-16 12:42:25 -0400 |
---|---|---|
committer | Ian Moffett <ian@osmora.org> | 2024-03-16 12:42:25 -0400 |
commit | 3db86a30644d3eb3a964202dbfd7e91c432bda7b (patch) | |
tree | 43d16c68f59c252075231f84e179fbdb68f00318 /sys/arch/amd64/amd64 | |
parent | 51a3988ec0ea1de35e47a999a76c14df05737a34 (diff) |
kernel: syscall: Remove syscall_args.ret
It is better to just return a value within the syscall handler and
have that passed down to __syscall() like that
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/arch/amd64/amd64')
-rw-r--r-- | sys/arch/amd64/amd64/syscall.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/arch/amd64/amd64/syscall.c b/sys/arch/amd64/amd64/syscall.c index 9b1f988..e80fe94 100644 --- a/sys/arch/amd64/amd64/syscall.c +++ b/sys/arch/amd64/amd64/syscall.c @@ -39,13 +39,10 @@ __syscall(struct trapframe *tf) .arg2 = tf->rcx, .arg3 = tf->r8, .arg4 = tf->r9, - .sp = tf->rsp, - .ret = tf->rax, + .sp = tf->rsp }; if (args.code < __MAX_SYSCALLS) { - g_syscall_table[tf->rax](&args); + tf->rax = g_syscall_table[tf->rax](&args); } - - tf->rax = args.ret; } |