]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
libxfs: clean up _calc_dquots_per_chunk
authorDarrick J. Wong <darrick.wong@oracle.com>
Tue, 25 Oct 2016 01:47:36 +0000 (12:47 +1100)
committerDave Chinner <david@fromorbit.com>
Tue, 25 Oct 2016 01:47:36 +0000 (12:47 +1100)
Source kernel commit: 58d789678546d46d7bbd809dd7dab417c0f23655

The function xfs_calc_dquots_per_chunk takes a parameter in units
of basic blocks.  The kernel seems to get the units wrong, but
userspace got 'fixed' by commenting out the unnecessary conversion.
Fix both.

cc: <stable@vger.kernel.org>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
libxfs/xfs_dquot_buf.c

index 433abe48d65a8e02d8fc900c6e972199b44378d4..aae88548ecda8933fb0196433175179404de0cbc 100644 (file)
@@ -200,7 +200,6 @@ xfs_dquot_buf_verify_crc(
                ndquots = mp->m_quotainfo->qi_dqperchunk;
        else
                ndquots = xfs_calc_dquots_per_chunk(bp->b_length);
-//                                     XFS_BB_TO_FSB(mp, bp->b_length));
 
        for (i = 0; i < ndquots; i++, d++) {
                if (!xfs_verify_cksum((char *)d, sizeof(struct xfs_dqblk),