aboutsummaryrefslogtreecommitdiff
path: root/fs/bcachefs/data_update.c
diff options
context:
space:
mode:
authorGravatar Kent Overstreet <kent.overstreet@linux.dev> 2023-06-27 17:32:48 -0400
committerGravatar Kent Overstreet <kent.overstreet@linux.dev> 2023-10-22 17:10:05 -0400
commitf33c58fc46a9c5bd6cbf90edb6ce17fa3fd912d5 (patch)
treed8a245eb7cf6e7ef9d7a6fc0a02cf06ba917dc2e /fs/bcachefs/data_update.c
parentbcachefs: Fix a null ptr deref in bch2_fs_alloc() error path (diff)
downloadlinux-f33c58fc46a9c5bd6cbf90edb6ce17fa3fd912d5.tar.gz
linux-f33c58fc46a9c5bd6cbf90edb6ce17fa3fd912d5.tar.bz2
linux-f33c58fc46a9c5bd6cbf90edb6ce17fa3fd912d5.zip
bcachefs: Kill BTREE_INSERT_USE_RESERVE
Now that we have journal watermarks and alloc watermarks unified, BTREE_INSERT_USE_RESERVE is redundant and can be deleted. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/data_update.c')
-rw-r--r--fs/bcachefs/data_update.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/bcachefs/data_update.c b/fs/bcachefs/data_update.c
index cc79bcb6726c..3c918368b2ec 100644
--- a/fs/bcachefs/data_update.c
+++ b/fs/bcachefs/data_update.c
@@ -458,8 +458,7 @@ int bch2_data_update_init(struct btree_trans *trans,
m->op.compression_type =
bch2_compression_opt_to_type[io_opts.background_compression ?:
io_opts.compression];
- if (m->data_opts.btree_insert_flags & BTREE_INSERT_USE_RESERVE)
- m->op.watermark = BCH_WATERMARK_copygc;
+ m->op.watermark = m->data_opts.btree_insert_flags & BCH_WATERMARK_MASK;
bkey_for_each_ptr(ptrs, ptr)
percpu_ref_get(&bch_dev_bkey_exists(c, ptr->dev)->ref);