Revert "zhack: Add 'feature disable' command"

This reverts commit 8302528617 and
ebecfcd699 which broke the build.
While these patches do apply cleanly and passed previous test
runs they need to be updated to account for the changes made in
commit 241b541574.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Issue #3878
This commit is contained in:
Brian Behlendorf
2016-05-17 11:44:50 -07:00
parent 2587cd8f93
commit ada8258141
4 changed files with 6 additions and 142 deletions
-37
View File
@@ -380,43 +380,6 @@ feature_enable_sync(spa_t *spa, zfeature_info_t *feature, dmu_tx_t *tx)
}
}
/*
* This function is non-static for zhack; it should otherwise not be used
* outside this file.
*/
void
feature_disable_sync(spa_t *spa, zfeature_info_t *feature, dmu_tx_t *tx)
{
uint64_t descobj = spa->spa_feat_desc_obj;
uint64_t zapobj = feature->fi_can_readonly ?
spa->spa_feat_for_write_obj : spa->spa_feat_for_read_obj;
ASSERT(0 != zapobj);
ASSERT(zfeature_is_valid_guid(feature->fi_guid));
ASSERT3U(spa_version(spa), >=, SPA_VERSION_FEATURES);
if (zap_contains(spa->spa_meta_objset, descobj, feature->fi_guid) == 0)
VERIFY0(zap_remove(spa->spa_meta_objset, descobj,
feature->fi_guid, tx));
if (zap_contains(spa->spa_meta_objset, zapobj, feature->fi_guid) == 0)
VERIFY0(zap_remove(spa->spa_meta_objset, zapobj,
feature->fi_guid, tx));
spa_deactivate_mos_feature(spa, feature->fi_guid);
if (spa_feature_is_enabled(spa, SPA_FEATURE_ENABLED_TXG)) {
uint64_t txgobj = spa->spa_feat_enabled_txg_obj;
if (txgobj && (zap_contains(spa->spa_meta_objset,
txgobj, feature->fi_guid) == 0)) {
spa_feature_decr(spa, SPA_FEATURE_ENABLED_TXG, tx);
VERIFY0(zap_remove(spa->spa_meta_objset, txgobj,
feature->fi_guid, tx));
}
}
}
static void
feature_do_action(spa_t *spa, spa_feature_t fid, feature_action_t action,
dmu_tx_t *tx)