Re: [PATCH] xfs: fix refactor quota limits initialization

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

 



On Tue, May 15, 2018 at 06:01:08PM -0700, Darrick J. Wong wrote:
> dquot warning fields are be16, not be32.  Fix this mistake.
> 
> Signed-off-by: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
> ---
>  fs/xfs/xfs_qm.c |    6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/fs/xfs/xfs_qm.c b/fs/xfs/xfs_qm.c
> index 913d46d01bfc..c3e014bfc848 100644
> --- a/fs/xfs/xfs_qm.c
> +++ b/fs/xfs/xfs_qm.c
> @@ -636,11 +636,11 @@ xfs_qm_init_timelimits(
>  	if (ddqp->d_rtbtimer)
>  		qinf->qi_rtbtimelimit = be32_to_cpu(ddqp->d_rtbtimer);
>  	if (ddqp->d_bwarns)
> -		qinf->qi_bwarnlimit = be32_to_cpu(ddqp->d_bwarns);
> +		qinf->qi_bwarnlimit = be16_to_cpu(ddqp->d_bwarns);
>  	if (ddqp->d_iwarns)
> -		qinf->qi_iwarnlimit = be32_to_cpu(ddqp->d_iwarns);
> +		qinf->qi_iwarnlimit = be16_to_cpu(ddqp->d_iwarns);
>  	if (ddqp->d_rtbwarns)
> -		qinf->qi_rtbwarnlimit = be32_to_cpu(ddqp->d_rtbwarns);
> +		qinf->qi_rtbwarnlimit = be16_to_cpu(ddqp->d_rtbwarns);

Looks good.

Reviewed-by: Dave Chinner <dchinner@xxxxxxxxxx>

FWIW, this points out that we need to start de-typedef-ing the quota
code as well clean it up. We've been pretty good about this in the
rest of the XFS code over the years, perhaps it's time for the quota
code to catch up?

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx
--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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