diff options
| author | Darrick J. Wong <[email protected]> | 2024-11-04 04:19:35 +0000 |
|---|---|---|
| committer | Darrick J. Wong <[email protected]> | 2024-11-05 21:38:44 +0000 |
| commit | e0b5b97dde8e4737d06cb5888abd88373abc22df (patch) | |
| tree | 2e3bc144a4a8a44bd5b31281a9758b3e83ac1371 /fs/xfs/scrub/agheader.c | |
| parent | xfs: adjust min_block usage in xfs_verify_agbno (diff) | |
| download | kernel-e0b5b97dde8e4737d06cb5888abd88373abc22df.tar.gz kernel-e0b5b97dde8e4737d06cb5888abd88373abc22df.zip | |
xfs: move the min and max group block numbers to xfs_group
Move the min and max agblock numbers to the generic xfs_group structure
so that we can start building validators for extents within an rtgroup.
While we're at it, use check_add_overflow for the extent length
computation because that has much better overflow checking.
Signed-off-by: Darrick J. Wong <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Diffstat (limited to 'fs/xfs/scrub/agheader.c')
| -rw-r--r-- | fs/xfs/scrub/agheader.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/xfs/scrub/agheader.c b/fs/xfs/scrub/agheader.c index 05f5e94b9938..d037de6dd821 100644 --- a/fs/xfs/scrub/agheader.c +++ b/fs/xfs/scrub/agheader.c @@ -564,7 +564,7 @@ xchk_agf( /* Check the AG length */ eoag = be32_to_cpu(agf->agf_length); - if (eoag != pag->block_count) + if (eoag != pag_group(pag)->xg_block_count) xchk_block_set_corrupt(sc, sc->sa.agf_bp); /* Check the AGF btree roots and levels */ @@ -944,7 +944,7 @@ xchk_agi( /* Check the AG length */ eoag = be32_to_cpu(agi->agi_length); - if (eoag != pag->block_count) + if (eoag != pag_group(pag)->xg_block_count) xchk_block_set_corrupt(sc, sc->sa.agi_bp); /* Check btree roots and levels */ |
