xfs: check that bc_nlevels never overflows
authorDarrick J. Wong <djwong@kernel.org>
Thu, 16 Sep 2021 19:22:08 +0000 (12:22 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 14 Oct 2021 16:19:32 +0000 (09:19 -0700)
commit4c175af2ccd3e0d618b2af941e656fabc453c4af
tree2a0519dce6ab1e02868ece89176759d571b64709
parent1ba6fd34ca63feb4ee960d35b87262b6db37529a
xfs: check that bc_nlevels never overflows

Warn if we ever bump nlevels higher than the allowed maximum cursor
height.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Chandan Babu R <chandan.babu@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_btree.c
fs/xfs/libxfs/xfs_btree_staging.c