xfs
[Top] [All Lists]

Re: [PATCH 02/12] quota: Allow each filesystem to specify which quota ty

To: Jan Kara <jack@xxxxxxx>
Subject: Re: [PATCH 02/12] quota: Allow each filesystem to specify which quota types it supports
From: Christoph Hellwig <hch@xxxxxx>
Date: Thu, 23 Oct 2014 10:53:50 +0200
Cc: linux-fsdevel@xxxxxxxxxxxxxxx, linux-ext4@xxxxxxxxxxxxxxx, Dave Chinner <david@xxxxxxxxxxxxx>, xfs@xxxxxxxxxxx, cluster-devel@xxxxxxxxxx, Steven Whitehouse <swhiteho@xxxxxxxxxx>, Mark Fasheh <mfasheh@xxxxxxxx>, Joel Becker <jlbec@xxxxxxxxxxxx>, ocfs2-devel@xxxxxxxxxxxxxx, reiserfs-devel@xxxxxxxxxxxxxxx, Jeff Mahoney <jeffm@xxxxxxx>, Dave Kleikamp <shaggy@xxxxxxxxxx>, jfs-discussion@xxxxxxxxxxxxxxxxxxxxx, tytso@xxxxxxx, viro@xxxxxxxxxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <20141022165150.GA12809@xxxxxxxxxxxxx>
References: <1413902316-17997-1-git-send-email-jack@xxxxxxx> <1413902316-17997-3-git-send-email-jack@xxxxxxx> <20141022162915.GB18443@xxxxxx> <20141022165150.GA12809@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.17 (2007-11-01)
On Wed, Oct 22, 2014 at 06:51:50PM +0200, Jan Kara wrote:
>   So there are two reasons:
> 1) Currently if you call quotactl() with invalid quota type you'll get
> EINVAL. To maintain this with addition of project quotas you need to check
> the types early before calling check_quotactl_permission() and other
> checks.
> 
> 2) I didn't want filesystem quotactl callbacks to deal with quota types
> they don't support. Sure each fs could do a type check in the callback but
> this looked easier.
> 
> Now I see your point about s_dquot and I can move allowed_types out of
> s_dquot if that makes you happier. But otherwise what I did still seems as
> the best solution to me.

Moving it out of s_dquot seems very sensible to me.

<Prev in Thread] Current Thread [Next in Thread>