Commit 102a6a8f authored by Daniel Hill's avatar Daniel Hill Committed by Kent Overstreet

bcachefs: respect superblock discard flag.

We were accidentally using default mount options and overwriting the
discard flag.
Signed-off-by: default avatarDaniel Hill <daniel@gluo.nz>
Signed-off-by: default avatarKent Overstreet <kent.overstreet@linux.dev>
parent 30985537
...@@ -1167,9 +1167,6 @@ static struct bch_dev *__bch2_dev_alloc(struct bch_fs *c, ...@@ -1167,9 +1167,6 @@ static struct bch_dev *__bch2_dev_alloc(struct bch_fs *c,
ca->mi = bch2_mi_to_cpu(member); ca->mi = bch2_mi_to_cpu(member);
ca->uuid = member->uuid; ca->uuid = member->uuid;
if (opt_defined(c->opts, discard))
ca->mi.discard = opt_get(c->opts, discard);
if (percpu_ref_init(&ca->ref, bch2_dev_ref_complete, if (percpu_ref_init(&ca->ref, bch2_dev_ref_complete,
0, GFP_KERNEL) || 0, GFP_KERNEL) ||
percpu_ref_init(&ca->io_ref, bch2_dev_io_ref_complete, percpu_ref_init(&ca->io_ref, bch2_dev_io_ref_complete,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment