summaryrefslogtreecommitdiff
path: root/fs/bcachefs/dirent.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2023-12-07 12:39:13 -0500
committerKent Overstreet <kent.overstreet@linux.dev>2023-12-08 00:39:56 -0500
commit6d1980f0af439b5fd49b1bee2220deff6888792e (patch)
treebd2d9116e3fabb7ce0f6ad0720384f414857a40c /fs/bcachefs/dirent.h
parente59728883943c6820a0aa413db66a38f2e8c27bd (diff)
bcachefs: Fix deleted inode check for dirs
We could delete directories transactionally on rmdir()/unlink(), but we don't; instead, like with regular files we wait for the VFS to call evict(). That means that our check for directories in the deleted inodes btree is wrong - the check should be for non-empty directories. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/dirent.h')
-rw-r--r--fs/bcachefs/dirent.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/bcachefs/dirent.h b/fs/bcachefs/dirent.h
index cd262bf4d9c5..1e3431990abd 100644
--- a/fs/bcachefs/dirent.h
+++ b/fs/bcachefs/dirent.h
@@ -64,6 +64,7 @@ u64 bch2_dirent_lookup(struct bch_fs *, subvol_inum,
const struct bch_hash_info *,
const struct qstr *, subvol_inum *);
+int bch2_empty_dir_snapshot(struct btree_trans *, u64, u32);
int bch2_empty_dir_trans(struct btree_trans *, subvol_inum);
int bch2_readdir(struct bch_fs *, subvol_inum, struct dir_context *);