diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2022-04-13 02:03:19 +0200 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 23:09:31 +0200 |
commit | 75c8d0305a5eecbe84b8ffef20e1c049f30f4123 (patch) | |
tree | 76073d5a57ad71416d86807bd304791943e25d43 /fs/bcachefs/recovery.c | |
parent | bcachefs: In fsck, pass BTREE_UPDATE_INTERNAL_SNAPSHOT_NODE when deleting dir... (diff) | |
download | linux-75c8d0305a5eecbe84b8ffef20e1c049f30f4123.tar.xz linux-75c8d0305a5eecbe84b8ffef20e1c049f30f4123.zip |
bcachefs: Kill old rebuild_replicas option
This option was useful when the replicas mechism was new and still being
debugged, but hasn't been used in ages - let's delete it.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to '')
-rw-r--r-- | fs/bcachefs/recovery.c | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/fs/bcachefs/recovery.c b/fs/bcachefs/recovery.c index dc11eae1bcaa..e2474ff99702 100644 --- a/fs/bcachefs/recovery.c +++ b/fs/bcachefs/recovery.c @@ -1087,12 +1087,6 @@ int bch2_fs_recovery(struct bch_fs *c) c->opts.fix_errors = FSCK_OPT_YES; } - if (!c->replicas.entries || - c->opts.rebuild_replicas) { - bch_info(c, "building replicas info"); - set_bit(BCH_FS_REBUILD_REPLICAS, &c->flags); - } - if (!c->opts.nochanges) { if (c->sb.version < bcachefs_metadata_version_new_data_types) { bch_info(c, "version prior to new_data_types, upgrade and fsck required"); @@ -1224,10 +1218,7 @@ use_clean: if (!c->opts.fsck) set_bit(BCH_FS_FSCK_DONE, &c->flags); - if (c->opts.fsck || - !(c->sb.compat & (1ULL << BCH_COMPAT_alloc_info)) || - !(c->sb.compat & (1ULL << BCH_COMPAT_alloc_metadata)) || - test_bit(BCH_FS_REBUILD_REPLICAS, &c->flags)) { + if (c->opts.fsck) { bool metadata_only = c->opts.norecovery; bch_info(c, "checking allocations"); @@ -1236,24 +1227,24 @@ use_clean: if (ret) goto err; bch_verbose(c, "done checking allocations"); - } - if (c->opts.fsck) { bch_info(c, "checking need_discard and freespace btrees"); err = "error checking need_discard and freespace btrees"; ret = bch2_check_alloc_info(c); if (ret) goto err; + bch_verbose(c, "done checking need_discard and freespace btrees"); + bch_info(c, "checking lrus"); + err = "error checking lrus"; ret = bch2_check_lrus(c, true); if (ret) goto err; - bch_verbose(c, "done checking need_discard and freespace btrees"); + bch_verbose(c, "done checking lrus"); } bch2_stripes_heap_start(c); - clear_bit(BCH_FS_REBUILD_REPLICAS, &c->flags); set_bit(BCH_FS_INITIAL_GC_DONE, &c->flags); set_bit(BCH_FS_MAY_GO_RW, &c->flags); |