diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-11-28 19:47:26 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-01-01 11:47:39 -0500 |
commit | 48dade81760ed551898ec20f59ace7ac2f5620b3 (patch) | |
tree | 7cc0a0ebd157201d60c513f39e57efeb886cca05 /fs/bcachefs/alloc_foreground.c | |
parent | a276132c2d2bc4baaa9bcfd86419885bd9b8567e (diff) | |
download | linux-48dade81760ed551898ec20f59ace7ac2f5620b3.tar.gz linux-48dade81760ed551898ec20f59ace7ac2f5620b3.tar.bz2 linux-48dade81760ed551898ec20f59ace7ac2f5620b3.zip |
bcachefs: ONLY_SPECIFIED_DEVS doesn't mean ignore durability anymore
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/alloc_foreground.c')
-rw-r--r-- | fs/bcachefs/alloc_foreground.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/fs/bcachefs/alloc_foreground.c b/fs/bcachefs/alloc_foreground.c index 0e6157982607..a7e6554cc7dd 100644 --- a/fs/bcachefs/alloc_foreground.c +++ b/fs/bcachefs/alloc_foreground.c @@ -697,11 +697,9 @@ static int add_new_bucket(struct bch_fs *c, bch_dev_bkey_exists(c, ob->dev)->mi.durability; BUG_ON(*nr_effective >= nr_replicas); - BUG_ON(flags & BCH_WRITE_ONLY_SPECIFIED_DEVS); __clear_bit(ob->dev, devs_may_alloc->d); - *nr_effective += (flags & BCH_WRITE_ONLY_SPECIFIED_DEVS) - ? durability : 1; + *nr_effective += durability; *have_cache |= !durability; ob_push(c, ptrs, ob); |