aboutsummaryrefslogtreecommitdiffstats
path: root/module
diff options
context:
space:
mode:
authorGeorge Wilson <[email protected]>2014-05-19 12:04:04 -0800
committerBrian Behlendorf <[email protected]>2014-07-22 09:41:06 -0700
commit3c51c5cb1f1c6097ecbfd18aa1177ba0f67c215e (patch)
treedfb1885c45048cc3f43045b5cff16b968de50f8a /module
parent93cf20764a1be64a603020f54b45200e37b3877e (diff)
Illumos #4730 destroy metaslab group taskq
4730 metaslab group taskq should be destroyed in metaslab_group_destroy() Reviewed by: Alex Reece <[email protected]> Reviewed by: Matthew Ahrens <[email protected]> Reviewed by: Sebastien Roy <[email protected]> Reviewed by: Rich Lowe <[email protected]> Reviewed by: Dan McDonald <[email protected]> Approved by: Dan McDonald <[email protected]> References: https://www.illumos.org/issues/4730 https://github.com/illumos/illumos-gate/commit/be08211 Porting notes: Under ZFSonlinux, one of the effects of not destroying the taskq is that zdb would never exit (due to the SPL taskq implementation). Ported-by: Tim Chase <[email protected]> Signed-off-by: Prakash Surya <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #2488
Diffstat (limited to 'module')
-rw-r--r--module/zfs/metaslab.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/module/zfs/metaslab.c b/module/zfs/metaslab.c
index b4e390c98..46543a52b 100644
--- a/module/zfs/metaslab.c
+++ b/module/zfs/metaslab.c
@@ -333,7 +333,7 @@ metaslab_group_create(metaslab_class_t *mc, vdev_t *vd)
mg->mg_class = mc;
mg->mg_activation_count = 0;
- mg->mg_taskq = taskq_create("metaslab_group_tasksq", metaslab_load_pct,
+ mg->mg_taskq = taskq_create("metaslab_group_taskq", metaslab_load_pct,
minclsyspri, 10, INT_MAX, TASKQ_THREADS_CPU_PCT);
return (mg);
@@ -351,6 +351,7 @@ metaslab_group_destroy(metaslab_group_t *mg)
*/
ASSERT(mg->mg_activation_count <= 0);
+ taskq_destroy(mg->mg_taskq);
avl_destroy(&mg->mg_metaslab_tree);
mutex_destroy(&mg->mg_lock);
kmem_free(mg, sizeof (metaslab_group_t));