summaryrefslogtreecommitdiffstats
path: root/fs/bcachefs/dirent.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2021-08-30 21:18:31 +0200
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-22 23:09:11 +0200
commit67e0dd8f0d8b4bf09098c4692abcb43a20089dff (patch)
tree8ba50f2d86b09cae23a39a02982abff3524e2f45 /fs/bcachefs/dirent.h
parentbcachefs: Fix initialization of bch_write_op.nonce (diff)
downloadlinux-67e0dd8f0d8b4bf09098c4692abcb43a20089dff.tar.xz
linux-67e0dd8f0d8b4bf09098c4692abcb43a20089dff.zip
bcachefs: btree_path
This splits btree_iter into two components: btree_iter is now the externally visible componont, and it points to a btree_path which is now reference counted. This means we no longer have to clone iterators up front if they might be mutated - btree_path can be shared by multiple iterators, and cloned if an iterator would mutate a shared btree_path. This will help us use iterators more efficiently, as well as slimming down the main long lived state in btree_trans, and significantly cleans up the logic for iterator lifetimes. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/dirent.h')
-rw-r--r--fs/bcachefs/dirent.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/bcachefs/dirent.h b/fs/bcachefs/dirent.h
index e1d8ce377d43..c14f6029e1c9 100644
--- a/fs/bcachefs/dirent.h
+++ b/fs/bcachefs/dirent.h
@@ -50,8 +50,7 @@ int bch2_dirent_rename(struct btree_trans *,
const struct qstr *, u64 *, u64 *,
enum bch_rename_mode);
-struct btree_iter *
-__bch2_dirent_lookup_trans(struct btree_trans *, u64,
+int __bch2_dirent_lookup_trans(struct btree_trans *, struct btree_iter *, u64,
const struct bch_hash_info *,
const struct qstr *, unsigned);
u64 bch2_dirent_lookup(struct bch_fs *, u64, const struct bch_hash_info *,