diff options
author | Darrick J. Wong <djwong@kernel.org> | 2023-04-11 19:00:12 -0700 |
---|---|---|
committer | Darrick J. Wong <djwong@kernel.org> | 2023-04-11 19:00:12 -0700 |
commit | 7ac14fa2bd22e99a06ae16382b394f697cfe2b8a (patch) | |
tree | 3e6c512aed6eee6657110fb2943600036cffb4b1 /fs/xfs/scrub/scrub.h | |
parent | 7ad9ea6398feae3ae4ce79fe08457f93b79a9a43 (diff) |
xfs: ensure that all metadata and data blocks are not cow staging extentsscrub-detect-refcount-gaps-6.4_2023-04-12scrub-detect-refcount-gaps-6.4_2023-04-11
Make sure that all filesystem metadata blocks and file data blocks are
not also marked as CoW staging extents. The extra checking added here
was inspired by an actual VM host filesystem corruption incident due to
bugs in the CoW handling of 4.x kernels.
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/scrub/scrub.h')
-rw-r--r-- | fs/xfs/scrub/scrub.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/xfs/scrub/scrub.h b/fs/xfs/scrub/scrub.h index d85c3b883b4c..b6f452eb9645 100644 --- a/fs/xfs/scrub/scrub.h +++ b/fs/xfs/scrub/scrub.h @@ -172,6 +172,8 @@ void xchk_xref_is_cow_staging(struct xfs_scrub *sc, xfs_agblock_t bno, xfs_extlen_t len); void xchk_xref_is_not_shared(struct xfs_scrub *sc, xfs_agblock_t bno, xfs_extlen_t len); +void xchk_xref_is_not_cow_staging(struct xfs_scrub *sc, xfs_agblock_t bno, + xfs_extlen_t len); #ifdef CONFIG_XFS_RT void xchk_xref_is_used_rt_space(struct xfs_scrub *sc, xfs_rtblock_t rtbno, xfs_extlen_t len); |