* CDDL HEADER END
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
-
-
#include <sys/zfs_context.h>
int taskq_now;
+taskq_t *system_taskq;
typedef struct task {
struct task *task_next;
}
for (t = 0; t < nthreads; t++)
- VERIFY(thr_create(0, 0, taskq_thread,
- tq, THR_BOUND, &tq->tq_threadlist[t]) == 0);
+ (void) thr_create(0, 0, taskq_thread,
+ tq, THR_BOUND, &tq->tq_threadlist[t]);
return (tq);
}
mutex_exit(&tq->tq_lock);
for (t = 0; t < nthreads; t++)
- VERIFY(thr_join(tq->tq_threadlist[t], NULL, NULL) == 0);
+ (void) thr_join(tq->tq_threadlist[t], NULL, NULL);
kmem_free(tq->tq_threadlist, nthreads * sizeof (thread_t));
return (0);
}
+
+void
+system_taskq_init(void)
+{
+ system_taskq = taskq_create("system_taskq", 64, minclsyspri, 4, 512,
+ TASKQ_DYNAMIC | TASKQ_PREPOPULATE);
+}