summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2010-08-28 08:38:03 +0000
committerpjd <pjd@FreeBSD.org>2010-08-28 08:38:03 +0000
commit43af1b087779e4426dde7668da83f0f220587b3d (patch)
treed113c70c0437b5a63fc20e8c1f0e7c90ad949fee /sys/kern
parentf3ed6934bef86f684e6fe249ef4c5294f20e3d49 (diff)
downloadFreeBSD-src-43af1b087779e4426dde7668da83f0f220587b3d.zip
FreeBSD-src-43af1b087779e4426dde7668da83f0f220587b3d.tar.gz
Run all tasks from a proper context, with proper priority, etc.
Reviewed by: jhb MFC after: 1 month
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/subr_taskqueue.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/subr_taskqueue.c b/sys/kern/subr_taskqueue.c
index fcf235c..c0b1dd1 100644
--- a/sys/kern/subr_taskqueue.c
+++ b/sys/kern/subr_taskqueue.c
@@ -141,7 +141,6 @@ taskqueue_free(struct taskqueue *queue)
TQ_LOCK(queue);
queue->tq_flags &= ~TQ_FLAGS_ACTIVE;
- taskqueue_run(queue, &queue->tq_running);
taskqueue_terminate(queue->tq_threads, queue);
mtx_destroy(&queue->tq_mutex);
free(queue->tq_threads, M_TASKQUEUE);
@@ -372,6 +371,7 @@ taskqueue_thread_loop(void *arg)
break;
TQ_SLEEP(tq, tq, &tq->tq_mutex, 0, "-", 0);
}
+ taskqueue_run(tq, &running);
/* rendezvous with thread that asked us to terminate */
tq->tq_tcount--;
OpenPOWER on IntegriCloud