summaryrefslogtreecommitdiff
path: root/fs/xfs/libxfs/xfs_dir2_leaf.c
diff options
context:
space:
mode:
authorBrian Foster <bfoster@redhat.com>2019-02-07 10:45:47 -0800
committerDarrick J. Wong <darrick.wong@oracle.com>2019-02-11 16:07:01 -0800
commitb8f89801664f8413a88cf2c7539d1aeae07dd3c5 (patch)
treea109a552d7bd5e90572350a43d6853e8db9a817e /fs/xfs/libxfs/xfs_dir2_leaf.c
parent27df4f5045fc68766980c4dfba5ffc9ad1f71ebb (diff)
xfs: distinguish between bnobt and cntbt magic values
The allocation btree verifiers share code that is unable to detect cross-tree magic value corruptions such as a bnobt block with a cntbt magic value. Populate the b_ops->magic field of the associated verifier structures such that the structure verifier can check the magic value against the expected value based on tree type. The btree level check requires knowledge of the tree type to determine the appropriate maximum value. This was previously part of the hardcoded magic value checks. With that code removed, peek at the first magic value in the verifier to determine the expected tree type of the current block. Signed-off-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'fs/xfs/libxfs/xfs_dir2_leaf.c')
0 files changed, 0 insertions, 0 deletions