summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2019-02-10 19:16:55 -0500
committerKent Overstreet <kent.overstreet@gmail.com>2019-04-03 12:44:06 -0400
commit800945de4383643b8d0ba96a3d3fe005dc9de849 (patch)
tree162a9966b3cc8655839c5d69c9b9b0371f6e0c60
parentb08a2ab24b497ce62b98e0170dfe65f54c312d01 (diff)
bcachefs: no need to run gc when initializing new fs
-rw-r--r--fs/bcachefs/recovery.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/fs/bcachefs/recovery.c b/fs/bcachefs/recovery.c
index 7e50547cc51f..38187cc802f6 100644
--- a/fs/bcachefs/recovery.c
+++ b/fs/bcachefs/recovery.c
@@ -406,16 +406,11 @@ int bch2_fs_initialize(struct bch_fs *c)
mutex_unlock(&c->sb_lock);
set_bit(BCH_FS_ALLOC_READ_DONE, &c->flags);
+ set_bit(BCH_FS_INITIAL_GC_DONE, &c->flags);
for (i = 0; i < BTREE_ID_NR; i++)
bch2_btree_root_alloc(c, i);
- ret = bch2_gc(c, &journal, true);
- if (ret)
- goto err;
-
- set_bit(BCH_FS_INITIAL_GC_DONE, &c->flags);
-
err = "unable to allocate journal buckets";
for_each_online_member(ca, c, i)
if (bch2_dev_journal_alloc(ca)) {