xfs: remove XFS_BUF_TO_SBP
Just dereference bp->b_addr directly and make the code a little simpler and more clear. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
此提交包含在:
@@ -92,7 +92,7 @@ xchk_superblock(
|
||||
if (!xchk_process_error(sc, agno, XFS_SB_BLOCK(mp), &error))
|
||||
return error;
|
||||
|
||||
sb = XFS_BUF_TO_SBP(bp);
|
||||
sb = bp->b_addr;
|
||||
|
||||
/*
|
||||
* Verify the geometries match. Fields that are permanently
|
||||
|
@@ -49,7 +49,7 @@ xrep_superblock(
|
||||
|
||||
/* Copy AG 0's superblock to this one. */
|
||||
xfs_buf_zero(bp, 0, BBTOB(bp->b_length));
|
||||
xfs_sb_to_disk(XFS_BUF_TO_SBP(bp), &mp->m_sb);
|
||||
xfs_sb_to_disk(bp->b_addr, &mp->m_sb);
|
||||
|
||||
/* Write this to disk. */
|
||||
xfs_trans_buf_set_type(sc->tp, bp, XFS_BLFT_SB_BUF);
|
||||
|
新增問題並參考
封鎖使用者