add a copyin function for sigset so that we can use sigtimedwait1 from
emulations.
This commit is contained in:
parent
f0c33b337d
commit
d8bca0f24f
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: kern_time_50.c,v 1.19 2011/03/04 01:36:56 christos Exp $ */
|
||||
/* $NetBSD: kern_time_50.c,v 1.20 2011/11/18 03:34:13 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
|
||||
|
@ -29,7 +29,7 @@
|
|||
* POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_time_50.c,v 1.19 2011/03/04 01:36:56 christos Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_time_50.c,v 1.20 2011/11/18 03:34:13 christos Exp $");
|
||||
|
||||
#ifdef _KERNEL_OPT
|
||||
#include "opt_aio.h"
|
||||
|
@ -480,8 +480,8 @@ compat_50_sys___sigtimedwait(struct lwp *l,
|
|||
int res;
|
||||
|
||||
res = sigtimedwait1(l,
|
||||
(const struct sys_____sigtimedwait50_args *)uap, retval, copyout,
|
||||
tscopyin, tscopyout);
|
||||
(const struct sys_____sigtimedwait50_args *)uap, retval, copyin,
|
||||
copyout, tscopyin, tscopyout);
|
||||
if (!res)
|
||||
*retval = 0; /* XXX NetBSD<=5 was not POSIX compliant */
|
||||
return res;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: netbsd32_compat_50.c,v 1.19 2011/05/23 21:34:47 joerg Exp $ */
|
||||
/* $NetBSD: netbsd32_compat_50.c,v 1.20 2011/11/18 03:34:13 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2008 The NetBSD Foundation, Inc.
|
||||
|
@ -36,7 +36,7 @@
|
|||
* POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_50.c,v 1.19 2011/05/23 21:34:47 joerg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: netbsd32_compat_50.c,v 1.20 2011/11/18 03:34:13 christos Exp $");
|
||||
|
||||
#if defined(_KERNEL_OPT)
|
||||
#include "opt_sysv.h"
|
||||
|
@ -501,6 +501,7 @@ compat_50_netbsd32___sigtimedwait(struct lwp *l,
|
|||
NETBSD32TOP_UAP(timeout, struct timespec);
|
||||
|
||||
res = sigtimedwait1(l, &ua, retval,
|
||||
copyin,
|
||||
compat_50_netbsd32_sigtimedwait_put_info,
|
||||
compat_50_netbsd32_sigtimedwait_fetch_timeout,
|
||||
compat_50_netbsd32_sigtimedwait_put_timeout);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: netbsd32_signal.c,v 1.35 2011/02/03 21:45:31 joerg Exp $ */
|
||||
/* $NetBSD: netbsd32_signal.c,v 1.36 2011/11/18 03:34:13 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998, 2001 Matthew R. Green
|
||||
|
@ -27,7 +27,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: netbsd32_signal.c,v 1.35 2011/02/03 21:45:31 joerg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: netbsd32_signal.c,v 1.36 2011/11/18 03:34:13 christos Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -483,6 +483,7 @@ netbsd32_____sigtimedwait50(struct lwp *l, const struct netbsd32_____sigtimedwai
|
|||
NETBSD32TOP_UAP(timeout, struct timespec);
|
||||
|
||||
return sigtimedwait1(l, &ua, retval,
|
||||
copyin,
|
||||
netbsd32_sigtimedwait_put_info,
|
||||
netbsd32_sigtimedwait_fetch_timeout,
|
||||
netbsd32_sigtimedwait_put_timeout);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: sys_sig.c,v 1.35 2011/05/29 22:14:53 christos Exp $ */
|
||||
/* $NetBSD: sys_sig.c,v 1.36 2011/11/18 03:34:13 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc.
|
||||
|
@ -66,7 +66,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: sys_sig.c,v 1.35 2011/05/29 22:14:53 christos Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: sys_sig.c,v 1.36 2011/11/18 03:34:13 christos Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/kernel.h>
|
||||
|
@ -365,7 +365,7 @@ sys_____sigtimedwait50(struct lwp *l,
|
|||
const struct sys_____sigtimedwait50_args *uap, register_t *retval)
|
||||
{
|
||||
|
||||
return sigtimedwait1(l, uap, retval, copyout, copyin, copyout);
|
||||
return sigtimedwait1(l, uap, retval, copyin, copyout, copyin, copyout);
|
||||
}
|
||||
|
||||
int
|
||||
|
@ -697,7 +697,8 @@ sigaltstack1(struct lwp *l, const struct sigaltstack *nss,
|
|||
|
||||
int
|
||||
sigtimedwait1(struct lwp *l, const struct sys_____sigtimedwait50_args *uap,
|
||||
register_t *retval, copyout_t storeinf, copyin_t fetchts, copyout_t storets)
|
||||
register_t *retval, copyin_t fetchss, copyout_t storeinf, copyin_t fetchts,
|
||||
copyout_t storets)
|
||||
{
|
||||
/* {
|
||||
syscallarg(const sigset_t *) set;
|
||||
|
@ -734,7 +735,7 @@ sigtimedwait1(struct lwp *l, const struct sys_____sigtimedwait50_args *uap,
|
|||
timo = 0;
|
||||
}
|
||||
|
||||
error = copyin(SCARG(uap, set), &l->l_sigwaitset,
|
||||
error = (*fetchss)(SCARG(uap, set), &l->l_sigwaitset,
|
||||
sizeof(l->l_sigwaitset));
|
||||
if (error)
|
||||
return error;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: signalvar.h,v 1.81 2011/05/28 15:33:41 christos Exp $ */
|
||||
/* $NetBSD: signalvar.h,v 1.82 2011/11/18 03:34:13 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1991, 1993
|
||||
|
@ -180,7 +180,7 @@ void ksiginfo_queue_drain0(ksiginfoq_t *);
|
|||
|
||||
struct sys_____sigtimedwait50_args;
|
||||
int sigtimedwait1(struct lwp *, const struct sys_____sigtimedwait50_args *,
|
||||
register_t *, copyout_t, copyin_t, copyout_t);
|
||||
register_t *, copyin_t, copyout_t, copyin_t, copyout_t);
|
||||
|
||||
void signotify(struct lwp *);
|
||||
int sigispending(struct lwp *, int);
|
||||
|
|
Loading…
Reference in New Issue