diff options
author | alc <alc@FreeBSD.org> | 2003-04-29 06:33:03 +0000 |
---|---|---|
committer | alc <alc@FreeBSD.org> | 2003-04-29 06:33:03 +0000 |
commit | aaa246d5c511d0b80f1fabdd6a1b794afd7d1573 (patch) | |
tree | 475834dd8a655ab14758940ae13fc46721143897 /sys/alpha | |
parent | 7c8835e88ccb5496fe58c41ce1355929f812e613 (diff) | |
download | FreeBSD-src-aaa246d5c511d0b80f1fabdd6a1b794afd7d1573.zip FreeBSD-src-aaa246d5c511d0b80f1fabdd6a1b794afd7d1573.tar.gz |
- Remove unnecessary useracc() calls from osf1_sigreturn().
Diffstat (limited to 'sys/alpha')
-rw-r--r-- | sys/alpha/osf1/osf1_signal.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/sys/alpha/osf1/osf1_signal.c b/sys/alpha/osf1/osf1_signal.c index 3f03ef1..bc3e06c 100644 --- a/sys/alpha/osf1/osf1_signal.c +++ b/sys/alpha/osf1/osf1_signal.c @@ -572,21 +572,12 @@ osf1_sigreturn(struct thread *td, p = td->td_proc; scp = uap->sigcntxp; - mtx_lock(&Giant); - if (useracc((caddr_t)scp, sizeof (*scp), VM_PROT_READ) == 0 ) { - uprintf("uac fails\n"); - uprintf("scp: %p\n", scp); - } + /* - * Test and fetch the context structure. - * We grab it all at once for speed. + * Fetch the entire context structure at once for speed. */ - if (useracc((caddr_t)scp, sizeof (*scp), VM_PROT_READ) == 0 || - copyin((caddr_t)scp, (caddr_t)&ksc, sizeof ksc)) { - mtx_unlock(&Giant); + if (copyin((caddr_t)scp, (caddr_t)&ksc, sizeof ksc)) return (EFAULT); - } - mtx_unlock(&Giant); /* * Restore the user-supplied information. |