xfs: create a separate finobt verifier

The inobt verifier is reused for the inobt and finobt, which
prevents the ability to distinguish between magic values on a
per-tree basis. Create a separate finobt structure in preparation
for changes to enforce the appropriate magic value for the
associated tree. This patch has no functional change.

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>
This commit is contained in:
Brian Foster
2019-02-07 10:45:46 -08:00
committed by Darrick J. Wong
parent e34d3e74eb
commit 01e68f40bf
5 changed files with 15 additions and 5 deletions

View File

@@ -333,6 +333,13 @@ const struct xfs_buf_ops xfs_inobt_buf_ops = {
.verify_struct = xfs_inobt_verify,
};
const struct xfs_buf_ops xfs_finobt_buf_ops = {
.name = "xfs_finobt",
.verify_read = xfs_inobt_read_verify,
.verify_write = xfs_inobt_write_verify,
.verify_struct = xfs_inobt_verify,
};
STATIC int
xfs_inobt_keys_inorder(
struct xfs_btree_cur *cur,
@@ -389,7 +396,7 @@ static const struct xfs_btree_ops xfs_finobt_ops = {
.init_rec_from_cur = xfs_inobt_init_rec_from_cur,
.init_ptr_from_cur = xfs_finobt_init_ptr_from_cur,
.key_diff = xfs_inobt_key_diff,
.buf_ops = &xfs_inobt_buf_ops,
.buf_ops = &xfs_finobt_buf_ops,
.diff_two_keys = xfs_inobt_diff_two_keys,
.keys_inorder = xfs_inobt_keys_inorder,
.recs_inorder = xfs_inobt_recs_inorder,