diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2022-11-02 07:20:09 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2022-11-02 07:20:09 +0000 |
commit | 25e0991fac3fb544cdf18903c285de7e16343f0b (patch) | |
tree | 519f742e155fa5a8ff12898cb846cf6aa9c9c84e /sys/arch/riscv64 | |
parent | 31c7022553963522dee5f0765842216773d2cfe2 (diff) |
Clean up more ancient history: since 2015 the libc stubs for
fork/vfork/__tfork haven't cared about the second return register.
So, stop setting retval[1] in kern_fork.c and stop setting the
second return register in the MD child_return() routines.
With the above, we have no multi-register return values on LP64,
so stop touching that register in the trapframe on those archs.
testing miod@ and aoyama@
ok miod@
Diffstat (limited to 'sys/arch/riscv64')
-rw-r--r-- | sys/arch/riscv64/riscv64/syscall.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/arch/riscv64/riscv64/syscall.c b/sys/arch/riscv64/riscv64/syscall.c index 81685bfd608..1e1b2ce6ed5 100644 --- a/sys/arch/riscv64/riscv64/syscall.c +++ b/sys/arch/riscv64/riscv64/syscall.c @@ -1,4 +1,4 @@ -/* $OpenBSD: syscall.c,v 1.12 2022/02/22 13:34:23 visa Exp $ */ +/* $OpenBSD: syscall.c,v 1.13 2022/11/02 07:20:08 guenther Exp $ */ /* * Copyright (c) 2020 Brian Bamsch <bbamsch@google.com> @@ -84,14 +84,13 @@ svc_handler(trapframe_t *frame) } rval[0] = 0; - rval[1] = frame->tf_a[1]; + rval[1] = 0; error = mi_syscall(p, code, callp, args, rval); switch (error) { case 0: frame->tf_a[0] = rval[0]; - frame->tf_a[1] = rval[1]; frame->tf_t[0] = 0; /* syscall succeeded */ break; @@ -119,7 +118,6 @@ child_return(void *arg) struct trapframe *frame = process_frame(p); frame->tf_a[0] = 0; - frame->tf_a[1] = 1; frame->tf_t[0] = 0; /* no error */ KERNEL_UNLOCK(); |