summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_taskqueue.c
diff options
context:
space:
mode:
authorscottl <scottl@FreeBSD.org>2006-01-11 00:37:13 +0000
committerscottl <scottl@FreeBSD.org>2006-01-11 00:37:13 +0000
commita1e420856f366519c33d3c47bffbb9ea0a979a3e (patch)
treeb8d21d36b1757d493ab659d5be8656122c8f9e02 /sys/kern/subr_taskqueue.c
parent57bb28253247356d93a0af777972e8cc4e3bec53 (diff)
downloadFreeBSD-src-a1e420856f366519c33d3c47bffbb9ea0a979a3e.zip
FreeBSD-src-a1e420856f366519c33d3c47bffbb9ea0a979a3e.tar.gz
The interlock in taskqueue_terminate() is completely wrong for taskqueues
that use spinlocks. Remove it for now.
Diffstat (limited to 'sys/kern/subr_taskqueue.c')
-rw-r--r--sys/kern/subr_taskqueue.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/kern/subr_taskqueue.c b/sys/kern/subr_taskqueue.c
index 794b103..3cc8292 100644
--- a/sys/kern/subr_taskqueue.c
+++ b/sys/kern/subr_taskqueue.c
@@ -145,11 +145,7 @@ taskqueue_terminate(struct proc **pp, struct taskqueue *tq)
*pp = NULL;
if (p) {
wakeup_one(tq);
- PROC_LOCK(p); /* NB: insure we don't miss wakeup */
- TQ_UNLOCK(tq); /* let taskqueue thread run */
- TQ_SLEEP(tq, p, &p->p_mtx, PWAIT, "taskqueue_destroy", 0);
- PROC_UNLOCK(p);
- TQ_LOCK(tq);
+ TQ_SLEEP(tq, p, &tq->tq_mutex, PWAIT, "taskqueue_destroy", 0);
}
}
OpenPOWER on IntegriCloud