diff options
author | jeff <jeff@FreeBSD.org> | 2003-03-31 22:49:17 +0000 |
---|---|---|
committer | jeff <jeff@FreeBSD.org> | 2003-03-31 22:49:17 +0000 |
commit | 46e6ba39f10b4874298cd617b4db656bb562eb37 (patch) | |
tree | da7bdaf8a9eef1885d86203074ba0ad8ae222e7c /sys/alpha | |
parent | 803202f956e45b36a05029bd98db32041fa3a23d (diff) | |
download | FreeBSD-src-46e6ba39f10b4874298cd617b4db656bb562eb37.zip FreeBSD-src-46e6ba39f10b4874298cd617b4db656bb562eb37.tar.gz |
- Move p->p_sigmask to td->td_sigmask. Signal masks will be per thread with
a follow on commit to kern_sig.c
- signotify() now operates on a thread since unmasked pending signals are
stored in the thread.
- PS_NEEDSIGCHK moves to TDF_NEEDSIGCHK.
Diffstat (limited to 'sys/alpha')
-rw-r--r-- | sys/alpha/alpha/machdep.c | 18 | ||||
-rw-r--r-- | sys/alpha/osf1/osf1_signal.c | 29 |
2 files changed, 24 insertions, 23 deletions
diff --git a/sys/alpha/alpha/machdep.c b/sys/alpha/alpha/machdep.c index 273bda5..055d3f8 100644 --- a/sys/alpha/alpha/machdep.c +++ b/sys/alpha/alpha/machdep.c @@ -1501,9 +1501,9 @@ osigreturn(struct thread *td, * sigmask is stored in sc_reserved, sc_mask is only used for * backward compatibility. */ - SIGSETOLD(p->p_sigmask, ksc.sc_mask); - SIG_CANTMASK(p->p_sigmask); - signotify(p); + SIGSETOLD(td->td_sigmask, ksc.sc_mask); + SIG_CANTMASK(td->td_sigmask); + signotify(td); PROC_UNLOCK(p); set_regs(td, (struct reg *)ksc.sc_regs); @@ -1583,9 +1583,9 @@ freebsd4_sigreturn(struct thread *td, p->p_sigstk.ss_flags &= ~SS_ONSTACK; #endif - p->p_sigmask = uc.uc_sigmask; - SIG_CANTMASK(p->p_sigmask); - signotify(p); + td->td_sigmask = uc.uc_sigmask; + SIG_CANTMASK(td->td_sigmask); + signotify(td); PROC_UNLOCK(p); /* XXX ksc.sc_ownedfp ? */ @@ -1659,9 +1659,9 @@ sigreturn(struct thread *td, p->p_sigstk.ss_flags &= ~SS_ONSTACK; #endif - p->p_sigmask = uc.uc_sigmask; - SIG_CANTMASK(p->p_sigmask); - signotify(p); + td->td_sigmask = uc.uc_sigmask; + SIG_CANTMASK(td->td_sigmask); + signotify(td); PROC_UNLOCK(p); return (EJUSTRETURN); diff --git a/sys/alpha/osf1/osf1_signal.c b/sys/alpha/osf1/osf1_signal.c index 718c7d9..8249c7a 100644 --- a/sys/alpha/osf1/osf1_signal.c +++ b/sys/alpha/osf1/osf1_signal.c @@ -451,7 +451,7 @@ osf1_signal(td, uap) bmask = stackgap_alloc(&sg, sizeof(sigset_t)); PROC_LOCK(p); - set = p->p_sigmask; + set = td->td_sigmask; PROC_UNLOCK(p); SIGDELSET(set, signum); sa.sigmask = bmask; @@ -481,7 +481,7 @@ osf1_sigprocmask(td, uap) p = td->td_proc; error = 0; /* Fix the return value first if needed */ - bsd_to_osf1_sigset(&p->p_sigmask, &oss); + bsd_to_osf1_sigset(&td->td_sigmask, &oss); td->td_retval[0] = oss; osf1_to_bsd_sigset(&uap->mask, &bss); @@ -490,19 +490,19 @@ osf1_sigprocmask(td, uap) switch (uap->how) { case OSF1_SIG_BLOCK: - SIGSETOR(p->p_sigmask, bss); - SIG_CANTMASK(p->p_sigmask); + SIGSETOR(td->td_sigmask, bss); + SIG_CANTMASK(td->td_sigmask); break; case OSF1_SIG_UNBLOCK: - SIGSETNAND(p->p_sigmask, bss); - signotify(p); + SIGSETNAND(td->td_sigmask, bss); + signotify(td); break; case OSF1_SIG_SETMASK: - p->p_sigmask = bss; - SIG_CANTMASK(p->p_sigmask); - signotify(p); + td->td_sigmask = bss; + SIG_CANTMASK(td->td_sigmask); + signotify(td); break; default: @@ -528,8 +528,9 @@ osf1_sigpending(td, uap) p = td->td_proc; PROC_LOCK(p); - bss = p->p_siglist; - SIGSETAND(bss, p->p_sigmask); + bss = td->td_siglist; + SIGSETOR(bss, p->p_siglist); + SIGSETAND(bss, td->td_sigmask); PROC_UNLOCK(p); bsd_to_osf1_sigset(&bss, &oss); @@ -727,9 +728,9 @@ osf1_sigreturn(struct thread *td, * sigmask is stored in sc_reserved, sc_mask is only used for * backward compatibility. */ - osf1_to_bsd_sigset(&ksc.sc_mask, &p->p_sigmask); - SIG_CANTMASK(p->p_sigmask); - signotify(p); + osf1_to_bsd_sigset(&ksc.sc_mask, &td->td_sigmask); + SIG_CANTMASK(td->td_sigmask); + signotify(td); PROC_UNLOCK(p); set_regs(td, (struct reg *)ksc.sc_regs); |