Use different dummy wait channels to avoid panic in msleep().

Reviewed by:	jhb
This commit is contained in:
Dag-Erling Smørgrav 2004-03-03 23:03:18 +00:00
parent 8dcb5306ef
commit 86b5e56351

View File

@ -925,7 +925,7 @@ kern_sigtimedwait(struct thread *td, sigset_t waitset, siginfo_t *info,
hz = 0;
td->td_waitset = &waitset;
error = msleep(ps, &p->p_mtx, PPAUSE|PCATCH, "sigwait", hz);
error = msleep(&ps, &p->p_mtx, PPAUSE|PCATCH, "sigwait", hz);
td->td_waitset = NULL;
if (error == 0) /* surplus wakeup ? */
error = EINTR;
@ -1153,7 +1153,7 @@ kern_sigsuspend(struct thread *td, sigset_t mask)
SIG_CANTMASK(mask);
td->td_sigmask = mask;
signotify(td);
while (msleep(p->p_sigacts, &p->p_mtx, PPAUSE|PCATCH, "pause", 0) == 0)
while (msleep(&p->p_sigacts, &p->p_mtx, PPAUSE|PCATCH, "pause", 0) == 0)
/* void */;
PROC_UNLOCK(p);
/* always return EINTR rather than ERESTART... */
@ -1189,7 +1189,7 @@ osigsuspend(td, uap)
SIG_CANTMASK(mask);
SIGSETLO(td->td_sigmask, mask);
signotify(td);
while (msleep(p->p_sigacts, &p->p_mtx, PPAUSE|PCATCH, "opause", 0) == 0)
while (msleep(&p->p_sigacts, &p->p_mtx, PPAUSE|PCATCH, "opause", 0) == 0)
/* void */;
PROC_UNLOCK(p);
/* always return EINTR rather than ERESTART... */