[06/10] xfs: teach xfs_btree_[sl]block_verify_crc to populate verifier context
diff mbox series

Message ID d45b96da-4ad1-3099-756e-8970934742f5@redhat.com
State New
Headers show
Series
  • xfs: add verifier context structure
Related show

Commit Message

Eric Sandeen Dec. 5, 2018, 9:06 p.m. UTC
Rather than simply returning true/false, populate the verifier
context as well.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
 fs/xfs/libxfs/xfs_btree.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Patch
diff mbox series

diff --git a/fs/xfs/libxfs/xfs_btree.c b/fs/xfs/libxfs/xfs_btree.c
index d4728f70fcc3..0b88cb04a719 100644
--- a/fs/xfs/libxfs/xfs_btree.c
+++ b/fs/xfs/libxfs/xfs_btree.c
@@ -297,11 +297,11 @@  xfs_btree_lblock_verify_crc(
 
 	if (xfs_sb_version_hascrc(&mp->m_sb)) {
 		if (!xfs_log_check_lsn(mp, be64_to_cpu(block->bb_u.l.bb_lsn)))
-			return false;
+			return XFS_CORRUPTED_RETURN(vc);
 		return xfs_buf_verify_cksum(vc, bp, XFS_BTREE_LBLOCK_CRC_OFF);
 	}
 
-	return true;
+	return XFS_VERIFIED_RETURN(vc);
 }
 
 /*
@@ -336,11 +336,11 @@  xfs_btree_sblock_verify_crc(
 
 	if (xfs_sb_version_hascrc(&mp->m_sb)) {
 		if (!xfs_log_check_lsn(mp, be64_to_cpu(block->bb_u.s.bb_lsn)))
-			return false;
+			return XFS_CORRUPTED_RETURN(vc);
 		return xfs_buf_verify_cksum(vc, bp, XFS_BTREE_SBLOCK_CRC_OFF);
 	}
 
-	return true;
+	return XFS_VERIFIED_RETURN(vc);
 }
 
 static int