diff options
author | Darrick J. Wong <darrick.wong@oracle.com> | 2018-01-16 18:53:06 -0800 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2018-01-17 21:00:45 -0800 |
commit | 52dc4b44af74196ded6413304542ead0257b5cda (patch) | |
tree | f5896fc577ede48201cefa0ae25b5ae28113c147 /fs/xfs/scrub/rmap.c | |
parent | 166d76410d7ac08ba2fd90f33ebb545e21fd6b3a (diff) | |
download | lwn-52dc4b44af74196ded6413304542ead0257b5cda.tar.gz lwn-52dc4b44af74196ded6413304542ead0257b5cda.zip |
xfs: cross-reference with the bnobt
When we're scrubbing various btrees, cross-reference the records with
the bnobt to ensure that we don't also think the space is free.
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/scrub/rmap.c')
-rw-r--r-- | fs/xfs/scrub/rmap.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/xfs/scrub/rmap.c b/fs/xfs/scrub/rmap.c index 865594895920..54b0eac22707 100644 --- a/fs/xfs/scrub/rmap.c +++ b/fs/xfs/scrub/rmap.c @@ -57,8 +57,13 @@ xfs_scrub_rmapbt_xref( struct xfs_scrub_context *sc, struct xfs_rmap_irec *irec) { + xfs_agblock_t agbno = irec->rm_startblock; + xfs_extlen_t len = irec->rm_blockcount; + if (sc->sm->sm_flags & XFS_SCRUB_OFLAG_CORRUPT) return; + + xfs_scrub_xref_is_used_space(sc, agbno, len); } /* Scrub an rmapbt record. */ |