summaryrefslogtreecommitdiff
path: root/fs/xfs/libxfs/xfs_bmap.h
diff options
context:
space:
mode:
authorDarrick J. Wong <djwong@kernel.org>2023-04-11 19:00:05 -0700
committerDarrick J. Wong <djwong@kernel.org>2023-04-11 19:00:05 -0700
commit6a3bd8fcf9afb47c703cb268f30f60aa2e7af86a (patch)
treef8853f97098e6394e60fdd7cc07ae74d48257d72 /fs/xfs/libxfs/xfs_bmap.h
parentee12eaaa435a7be17152ac50943ee77249de624a (diff)
xfs: complain about bad file mapping records in the ondisk bmbtbtree-complain-bad-records-6.4_2023-04-12btree-complain-bad-records-6.4_2023-04-11
Similar to what we've just done for the other btrees, create a function to log corrupt bmbt records and call it whenever we encounter a bad record in the ondisk btree. Signed-off-by: Darrick J. Wong <djwong@kernel.org> Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/libxfs/xfs_bmap.h')
-rw-r--r--fs/xfs/libxfs/xfs_bmap.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_bmap.h b/fs/xfs/libxfs/xfs_bmap.h
index e5a492027aea..9ff030d12981 100644
--- a/fs/xfs/libxfs/xfs_bmap.h
+++ b/fs/xfs/libxfs/xfs_bmap.h
@@ -265,6 +265,8 @@ static inline uint32_t xfs_bmap_fork_to_state(int whichfork)
xfs_failaddr_t xfs_bmap_validate_extent(struct xfs_inode *ip, int whichfork,
struct xfs_bmbt_irec *irec);
+int xfs_bmap_complain_bad_rec(struct xfs_inode *ip, int whichfork,
+ xfs_failaddr_t fa, const struct xfs_bmbt_irec *irec);
int xfs_bmapi_remap(struct xfs_trans *tp, struct xfs_inode *ip,
xfs_fileoff_t bno, xfs_filblks_t len, xfs_fsblock_t startblock,