diff options
| author | Kent Overstreet <kent.overstreet@linux.dev> | 2024-09-28 14:27:24 -0400 |
|---|---|---|
| committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-12-21 01:36:14 -0500 |
| commit | de92b1ee679bfdf97e6dcd7d4815c53606ea5f01 (patch) | |
| tree | b83a05bb3c67ad9552bd1b8964b867fd84055034 | |
| parent | 1c6d5841aebcad7d1a63e242780e400db6efcf97 (diff) | |
bcachefs: bch2_inode_should_have_bp -> bch2_inode_should_have_single_bp
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
| -rw-r--r-- | fs/bcachefs/fs.c | 2 | ||||
| -rw-r--r-- | fs/bcachefs/fsck.c | 2 | ||||
| -rw-r--r-- | fs/bcachefs/inode.h | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/fs/bcachefs/fs.c b/fs/bcachefs/fs.c index a41d0d8a2f7b..646b74494a3f 100644 --- a/fs/bcachefs/fs.c +++ b/fs/bcachefs/fs.c @@ -628,7 +628,7 @@ static struct bch_inode_info *bch2_lookup_trans(struct btree_trans *trans, goto err; /* regular files may have hardlinks: */ - if (bch2_fs_inconsistent_on(bch2_inode_should_have_bp(&inode_u) && + if (bch2_fs_inconsistent_on(bch2_inode_should_have_single_bp(&inode_u) && !bkey_eq(k.k->p, POS(inode_u.bi_dir, inode_u.bi_dir_offset)), c, "dirent points to inode that does not point back:\n %s", diff --git a/fs/bcachefs/fsck.c b/fs/bcachefs/fsck.c index 75c8a97a6954..285de12436dd 100644 --- a/fs/bcachefs/fsck.c +++ b/fs/bcachefs/fsck.c @@ -2156,7 +2156,7 @@ static int check_dirent_inode_dirent(struct btree_trans *trans, return __bch2_fsck_write_inode(trans, target); } - if (bch2_inode_should_have_bp(target) && + if (bch2_inode_should_have_single_bp(target) && !fsck_err(trans, inode_wrong_backpointer, "dirent points to inode that does not point back:\n %s", (bch2_bkey_val_to_text(&buf, c, d.s_c), diff --git a/fs/bcachefs/inode.h b/fs/bcachefs/inode.h index eab82b5eb897..bdeb6be76038 100644 --- a/fs/bcachefs/inode.h +++ b/fs/bcachefs/inode.h @@ -249,7 +249,7 @@ static inline void bch2_inode_nlink_set(struct bch_inode_unpacked *bi, int bch2_inode_nlink_inc(struct bch_inode_unpacked *); void bch2_inode_nlink_dec(struct btree_trans *, struct bch_inode_unpacked *); -static inline bool bch2_inode_should_have_bp(struct bch_inode_unpacked *inode) +static inline bool bch2_inode_should_have_single_bp(struct bch_inode_unpacked *inode) { bool inode_has_bp = inode->bi_dir || inode->bi_dir_offset; |
