Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/rump/librump/rumpkern add a hacky version of sigsuspends...



details:   https://anonhg.NetBSD.org/src/rev/8de596f0b973
branches:  trunk
changeset: 765076:8de596f0b973
user:      christos <christos%NetBSD.org@localhost>
date:      Wed May 18 15:57:14 2011 +0000

description:
add a hacky version of sigsuspendsetup() to satisfy link requirements.

diffstat:

 sys/rump/librump/rumpkern/signals.c |  18 ++++++++++++++++--
 1 files changed, 16 insertions(+), 2 deletions(-)

diffs (36 lines):

diff -r 0515770f6bb5 -r 8de596f0b973 sys/rump/librump/rumpkern/signals.c
--- a/sys/rump/librump/rumpkern/signals.c       Wed May 18 15:28:12 2011 +0000
+++ b/sys/rump/librump/rumpkern/signals.c       Wed May 18 15:57:14 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: signals.c,v 1.8 2011/02/20 13:09:57 pooka Exp $        */
+/*     $NetBSD: signals.c,v 1.9 2011/05/18 15:57:14 christos Exp $     */
 
 /*-
  * Copyright (c) 2010, 2011 Antti Kantee.  All Rights Reserved.
@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: signals.c,v 1.8 2011/02/20 13:09:57 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: signals.c,v 1.9 2011/05/18 15:57:14 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/atomic.h>
@@ -276,3 +276,17 @@
        sigemptyset(&p->p_sigctx.ps_sigignore);
        sigemptyset(&p->p_sigpend.sp_set);
 }
+
+void
+sigsuspendsetup(struct lwp *l, const sigset_t *ss)
+{
+       /* XXX: Partial copy of kernel code, remove and use the kernel code */
+       struct proc *p = l->l_proc;
+
+       mutex_enter(p->p_lock);
+       l->l_sigrestore = 1;
+       l->l_sigoldmask = l->l_sigmask;
+       l->l_sigmask = *ss;
+       sigminusset(&sigcantmask, &l->l_sigmask);
+       mutex_exit(p->p_lock);
+}



Home | Main Index | Thread Index | Old Index