From bcfcde4ea21cc19db1bd0531bf3e7b0175a7b34a Mon Sep 17 00:00:00 2001 From: Paul Dagnelie Date: Tue, 23 Jan 2024 13:34:22 -0800 Subject: [PATCH] Don't assert mg_initialized due to device addition race Signed-off-by: Paul Dagnelie --- module/zfs/metaslab.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/module/zfs/metaslab.c b/module/zfs/metaslab.c index 0983ba143a1d..7237fa8eeb59 100644 --- a/module/zfs/metaslab.c +++ b/module/zfs/metaslab.c @@ -5105,7 +5105,6 @@ metaslab_group_alloc(metaslab_group_t *mg, zio_alloc_list_t *zal, int allocator, boolean_t try_hard) { uint64_t offset; - ASSERT(mg->mg_initialized); offset = metaslab_group_alloc_normal(mg, zal, asize, txg, want_unique, dva, d, allocator, try_hard); @@ -5256,8 +5255,6 @@ metaslab_alloc_dva(spa_t *spa, metaslab_class_t *mc, uint64_t psize, goto next; } - ASSERT(mg->mg_initialized); - /* * Avoid writing single-copy data to an unhealthy, * non-redundant vdev, unless we've already tried all