[PATCH 2/3] xfs: use the proper conversion helpers in xfs_rt_check_size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Use the proper helpers to deal with sparse rtbno encoding.

Signed-off-by: Christoph Hellwig <hch@xxxxxx>
---
 fs/xfs/xfs_rtalloc.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/xfs/xfs_rtalloc.c b/fs/xfs/xfs_rtalloc.c
index 90f4fdd47087..a991b750df81 100644
--- a/fs/xfs/xfs_rtalloc.c
+++ b/fs/xfs/xfs_rtalloc.c
@@ -1233,13 +1233,13 @@ xfs_rt_check_size(
 	struct xfs_mount	*mp,
 	xfs_rfsblock_t		last_block)
 {
-	xfs_daddr_t		daddr = XFS_FSB_TO_BB(mp, last_block);
+	xfs_daddr_t		daddr = xfs_rtb_to_daddr(mp, last_block);
 	struct xfs_buf		*bp;
 	int			error;
 
-	if (XFS_BB_TO_FSB(mp, daddr) != last_block) {
+	if (xfs_daddr_to_rtb(mp, daddr) != last_block) {
 		xfs_warn(mp, "RT device size overflow: %llu != %llu",
-			XFS_BB_TO_FSB(mp, daddr), last_block);
+			xfs_daddr_to_rtb(mp, daddr), last_block);
 		return -EFBIG;
 	}
 
-- 
2.45.2





[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux