[PATCH v2] xfs: send warning of project quota to userspace via netlink
Brian Foster
bfoster at redhat.com
Thu Nov 26 07:49:33 CST 2015
On Thu, Nov 26, 2015 at 11:22:39AM +0900, Masatake YAMATO wrote:
> Linux's quota subsystem has an ability to handle
> project quota. This commit just utilizes the ability
> from xfs side.
>
...
> Changes in v2:
>
> a couple aesthetic things suggested by Brian Foster <bfoster at redhat.com>.
> * rename local vairable for aligning the parameter names,
> * move a short line to the end of its previous line.
>
> Signed-off-by: Masatake YAMATO <yamato at redhat.com>
> ---
Thanks for all of the test information. Now you have a really long
commit log description rather than a short one. ;) Maybe Dave can
truncate it. Regardless, looks fine to me:
Reviewed-by: Brian Foster <bfoster at redhat.com>
> fs/xfs/xfs_trans_dquot.c | 14 +++++++++-----
> 1 file changed, 9 insertions(+), 5 deletions(-)
>
> diff --git a/fs/xfs/xfs_trans_dquot.c b/fs/xfs/xfs_trans_dquot.c
> index ce78534..9951701 100644
> --- a/fs/xfs/xfs_trans_dquot.c
> +++ b/fs/xfs/xfs_trans_dquot.c
> @@ -572,12 +572,16 @@ xfs_quota_warn(
> struct xfs_dquot *dqp,
> int type)
> {
> - /* no warnings for project quotas - we just return ENOSPC later */
> + enum quota_type qtype;
> +
> if (dqp->dq_flags & XFS_DQ_PROJ)
> - return;
> - quota_send_warning(make_kqid(&init_user_ns,
> - (dqp->dq_flags & XFS_DQ_USER) ?
> - USRQUOTA : GRPQUOTA,
> + qtype = PRJQUOTA;
> + else if (dqp->dq_flags & XFS_DQ_USER)
> + qtype = USRQUOTA;
> + else
> + qtype = GRPQUOTA;
> +
> + quota_send_warning(make_kqid(&init_user_ns, qtype,
> be32_to_cpu(dqp->q_core.d_id)),
> mp->m_super->s_dev, type);
> }
> --
> 2.5.0
>
> _______________________________________________
> xfs mailing list
> xfs at oss.sgi.com
> http://oss.sgi.com/mailman/listinfo/xfs
More information about the xfs
mailing list