diff --git a/module/zfs/dmu_objset.c b/module/zfs/dmu_objset.c index 2f18075ae6..5083b17634 100644 --- a/module/zfs/dmu_objset.c +++ b/module/zfs/dmu_objset.c @@ -2408,6 +2408,13 @@ dmu_objset_id_quota_upgrade_cb(objset_t *os) dmu_objset_userobjspace_present(os)) return (SET_ERROR(ENOTSUP)); + if (dmu_objset_userobjused_enabled(os)) + dmu_objset_ds(os)->ds_feature_activation[ + SPA_FEATURE_USEROBJ_ACCOUNTING] = (void *)B_TRUE; + if (dmu_objset_projectquota_enabled(os)) + dmu_objset_ds(os)->ds_feature_activation[ + SPA_FEATURE_PROJECT_QUOTA] = (void *)B_TRUE; + err = dmu_objset_space_upgrade(os); if (err) return (err); diff --git a/module/zfs/dsl_dataset.c b/module/zfs/dsl_dataset.c index 0584a356f9..02eef6cda9 100644 --- a/module/zfs/dsl_dataset.c +++ b/module/zfs/dsl_dataset.c @@ -1759,25 +1759,6 @@ dsl_dataset_snapshot_sync_impl(dsl_dataset_t *ds, const char *snapname, } } - /* - * We are not allowed to dirty a filesystem when done receiving - * a snapshot. In this case some flags such as SPA_FEATURE_LARGE_BLOCKS - * will not be set and a subsequent encrypted raw send will fail. Hence - * activate this feature if needed here. This needs to happen only in - * syncing context. - */ - if (dmu_tx_is_syncing(tx)) { - for (spa_feature_t f = 0; f < SPA_FEATURES; f++) { - if (zfeature_active(f, ds->ds_feature_activation[f]) && - !(zfeature_active(f, ds->ds_feature[f]))) { - dsl_dataset_activate_feature(dsobj, f, - ds->ds_feature_activation[f], tx); - ds->ds_feature[f] = - ds->ds_feature_activation[f]; - } - } - } - ASSERT3U(ds->ds_prev != 0, ==, dsl_dataset_phys(ds)->ds_prev_snap_obj != 0); if (ds->ds_prev) { diff --git a/module/zfs/dsl_scan.c b/module/zfs/dsl_scan.c index f971aa211e..021cba68cd 100644 --- a/module/zfs/dsl_scan.c +++ b/module/zfs/dsl_scan.c @@ -2058,11 +2058,6 @@ dsl_scan_visitbp(blkptr_t *bp, const zbookmark_phys_t *zb, return; } - if (bp->blk_birth <= scn->scn_phys.scn_cur_min_txg) { - scn->scn_lt_min_this_txg++; - return; - } - bp_toread = kmem_alloc(sizeof (blkptr_t), KM_SLEEP); *bp_toread = *bp;