diff options
author | Darrick J. Wong <darrick.wong@oracle.com> | 2017-10-17 21:37:40 -0700 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2017-10-26 15:38:25 -0700 |
commit | efa7a99ce1f8615aca7b0ff3122a1ae14e4d1cdc (patch) | |
tree | d133547af1f14377606a6eee2ddcf23b9217e660 /fs/xfs/scrub/common.c | |
parent | a12890aebb895951720ff884eab1c99a30645b29 (diff) | |
download | linux-efa7a99ce1f8615aca7b0ff3122a1ae14e4d1cdc.tar.bz2 |
xfs: scrub free space btrees
Check the extent records free space btrees to ensure that the values
look sane.
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/scrub/common.c')
-rw-r--r-- | fs/xfs/scrub/common.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/fs/xfs/scrub/common.c b/fs/xfs/scrub/common.c index b0ba14cfac90..018127ad5018 100644 --- a/fs/xfs/scrub/common.c +++ b/fs/xfs/scrub/common.c @@ -443,3 +443,19 @@ xfs_scrub_setup_fs( { return xfs_scrub_trans_alloc(sc->sm, sc->mp, &sc->tp); } + +/* Set us up with AG headers and btree cursors. */ +int +xfs_scrub_setup_ag_btree( + struct xfs_scrub_context *sc, + struct xfs_inode *ip, + bool force_log) +{ + int error; + + error = xfs_scrub_setup_ag_header(sc, ip); + if (error) + return error; + + return xfs_scrub_ag_init(sc, sc->sm->sm_agno, &sc->sa); +} |