summaryrefslogtreecommitdiff
path: root/fs/bcachefs/alloc_background.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/bcachefs/alloc_background.c')
-rw-r--r--fs/bcachefs/alloc_background.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/bcachefs/alloc_background.c b/fs/bcachefs/alloc_background.c
index 4486ce0b7920..81e80f36af43 100644
--- a/fs/bcachefs/alloc_background.c
+++ b/fs/bcachefs/alloc_background.c
@@ -1719,7 +1719,8 @@ static int bch2_discard_one_bucket(struct btree_trans *trans,
write:
ret = bch2_trans_update(trans, &iter, &a->k_i, 0) ?:
bch2_trans_commit(trans, NULL, NULL,
- BTREE_INSERT_USE_RESERVE|BTREE_INSERT_NOFAIL);
+ BCH_WATERMARK_btree|
+ BTREE_INSERT_NOFAIL);
if (ret)
goto out;
@@ -1827,7 +1828,8 @@ static int invalidate_one_bucket(struct btree_trans *trans,
ret = bch2_trans_update(trans, &alloc_iter, &a->k_i,
BTREE_TRIGGER_BUCKET_INVALIDATE) ?:
bch2_trans_commit(trans, NULL, NULL,
- BTREE_INSERT_USE_RESERVE|BTREE_INSERT_NOFAIL);
+ BCH_WATERMARK_btree|
+ BTREE_INSERT_NOFAIL);
if (ret)
goto out;