xfs: validate ag btree levels using the precomputed values
authorDarrick J. Wong <djwong@kernel.org>
Mon, 22 Mar 2021 16:51:54 +0000 (09:51 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 25 Mar 2021 23:47:50 +0000 (16:47 -0700)
commit973975b72a36ee86c8c59057f06fcde03478ff4f
tree2af09dfd31c6f28eb94232f8f0dc2df4d021d3a7
parentf53acface7a9765ba03b491485bcc53d72810aeb
xfs: validate ag btree levels using the precomputed values

Use the AG btree height limits that we precomputed into the xfs_mount to
validate the AG headers instead of using XFS_BTREE_MAXLEVELS.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_alloc.c
fs/xfs/libxfs/xfs_ialloc.c
fs/xfs/libxfs/xfs_inode_fork.c