summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_sig.c
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2004-06-02 07:52:36 +0000
committertjr <tjr@FreeBSD.org>2004-06-02 07:52:36 +0000
commit80d36400edd04b536fd6cab0dae30c9e678e6598 (patch)
treedc1941eeb3f510a239f3f234b0c5aef4b268c958 /sys/kern/kern_sig.c
parent3bf088071bbb46981c2cb1cf2ad63132bf04048d (diff)
downloadFreeBSD-src-80d36400edd04b536fd6cab0dae30c9e678e6598.zip
FreeBSD-src-80d36400edd04b536fd6cab0dae30c9e678e6598.tar.gz
Move TDF_SA from td_flags to td_pflags (and rename it accordingly)
so that it is no longer necessary to hold sched_lock while manipulating it. Reviewed by: davidxu
Diffstat (limited to 'sys/kern/kern_sig.c')
-rw-r--r--sys/kern/kern_sig.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c
index 27ea15f..adda9bd 100644
--- a/sys/kern/kern_sig.c
+++ b/sys/kern/kern_sig.c
@@ -1490,7 +1490,7 @@ trapsignal(struct thread *td, int sig, u_long code)
int error;
p = td->td_proc;
- if (td->td_flags & TDF_SA) {
+ if (td->td_pflags & TDP_SA) {
if (td->td_mailbox == NULL)
thread_user_enter(p, td);
PROC_LOCK(p);
@@ -1524,7 +1524,7 @@ trapsignal(struct thread *td, int sig, u_long code)
ktrpsig(sig, ps->ps_sigact[_SIG_IDX(sig)],
&td->td_sigmask, code);
#endif
- if (!(td->td_flags & TDF_SA))
+ if (!(td->td_pflags & TDP_SA))
(*p->p_sysent->sv_sendsig)(
ps->ps_sigact[_SIG_IDX(sig)], sig,
&td->td_sigmask, code);
@@ -2291,7 +2291,7 @@ postsig(sig)
mtx_lock(&ps->ps_mtx);
}
- if (!(td->td_flags & TDF_SA && td->td_mailbox) &&
+ if (!(td->td_pflags & TDP_SA && td->td_mailbox) &&
action == SIG_DFL) {
/*
* Default action, where the default is to kill
@@ -2301,7 +2301,7 @@ postsig(sig)
sigexit(td, sig);
/* NOTREACHED */
} else {
- if (td->td_flags & TDF_SA && td->td_mailbox) {
+ if (td->td_pflags & TDP_SA && td->td_mailbox) {
if (sig == SIGKILL) {
mtx_unlock(&ps->ps_mtx);
sigexit(td, sig);
@@ -2350,7 +2350,7 @@ postsig(sig)
p->p_code = 0;
p->p_sig = 0;
}
- if (td->td_flags & TDF_SA && td->td_mailbox)
+ if (td->td_pflags & TDP_SA && td->td_mailbox)
thread_signal_add(curthread, sig);
else
(*p->p_sysent->sv_sendsig)(action, sig,
OpenPOWER on IntegriCloud