xfs: move the min and max group block numbers to xfs_group
authorDarrick J. Wong <djwong@kernel.org>
Mon, 4 Nov 2024 04:19:35 +0000 (20:19 -0800)
committerDarrick J. Wong <djwong@kernel.org>
Tue, 5 Nov 2024 21:38:44 +0000 (13:38 -0800)
commite0b5b97dde8e4737d06cb5888abd88373abc22df
tree2e3bc144a4a8a44bd5b31281a9758b3e83ac1371
parentceaa0bd773e2d6d5726d6535f605ecd6b26d2fcc
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 <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_ag.c
fs/xfs/libxfs/xfs_ag.h
fs/xfs/libxfs/xfs_group.h
fs/xfs/libxfs/xfs_ialloc_btree.c
fs/xfs/libxfs/xfs_rtgroup.c
fs/xfs/libxfs/xfs_rtgroup.h
fs/xfs/scrub/agheader.c
fs/xfs/scrub/agheader_repair.c
fs/xfs/scrub/repair.c
fs/xfs/xfs_discard.c
fs/xfs/xfs_rtalloc.c