From ef15ddcd30a0e710eff7f0e693fcbb1f659221e4 Mon Sep 17 00:00:00 2001 From: Paul Dagnelie Date: Wed, 28 Jun 2023 14:59:30 -0700 Subject: [PATCH] enhance test to cover feature Signed-off-by: Paul Dagnelie --- module/zfs/dsl_destroy.c | 6 ++++-- .../functional/redacted_send/redacted_many_clones.ksh | 7 +++++++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/module/zfs/dsl_destroy.c b/module/zfs/dsl_destroy.c index 0074aba294ad..d9d88a981e05 100644 --- a/module/zfs/dsl_destroy.c +++ b/module/zfs/dsl_destroy.c @@ -1127,10 +1127,12 @@ dsl_destroy_head_sync_impl(dsl_dataset_t *ds, dmu_tx_t *tx) if (dbn->dbn_phys.zbm_redaction_obj != 0) { dnode_t *rl; VERIFY0(dnode_hold(mos, - dbn->dbn_phys.zbm_redaction_obj, FTAG, &rl)); + dbn->dbn_phys.zbm_redaction_obj, FTAG, + &rl)); if (rl->dn_have_spill) { spa_feature_decr(dmu_objset_spa(mos), - SPA_FEATURE_REDACTION_LIST_SPILL, tx); + SPA_FEATURE_REDACTION_LIST_SPILL, + tx); } dnode_rele(rl, FTAG); VERIFY0(dmu_object_free(mos, diff --git a/tests/zfs-tests/tests/functional/redacted_send/redacted_many_clones.ksh b/tests/zfs-tests/tests/functional/redacted_send/redacted_many_clones.ksh index 9c33f957c290..f2150be3bc95 100755 --- a/tests/zfs-tests/tests/functional/redacted_send/redacted_many_clones.ksh +++ b/tests/zfs-tests/tests/functional/redacted_send/redacted_many_clones.ksh @@ -62,4 +62,11 @@ log_must eval "zfs send --redact book1 $sendfs@snap >$stream" log_must eval "zfs recv $recvfs <$stream" compare_files $sendfs $recvfs "f2" "$RANGE8" +rls_value="$(zpool get -H -o value feature@redaction_list_spill $POOL)" +if [ "$rls_value" = "active" ]; then + log_note "redaction_list_spill feature active" +else + log_fail "redaction_list_spill feature not active" +fi + log_pass "Redacted send can deal with a large redaction list."