Re: [PATCH 3/3] quota: unify ->set_dqblk

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

 



On Wed 05-05-10 06:39:40, Christoph Hellwig wrote:
> Pass the larger struct fs_disk_quota to the ->set_dqblk operation so
> that the Q_SETQUOTA and Q_XSETQUOTA operations can be implemented
> with a single filesystem operation and we can retire the ->set_xquota
> operation.  The additional information (RT-subvolume accounting and
> warn counts) are left zero for the VFS quota implementation.
> 
> Add new fieldmask values for setting the numer of blocks and inodes
> values which is required for the VFS quota, but wasn't for XFS.
> 
> Signed-off-by: Christoph Hellwig <hch@xxxxxx>
> 
  Just one minor nit below...

...
> @@ -2405,11 +2424,14 @@ static int do_set_dqblk(struct dquot *dq
>  }
>  
>  int vfs_set_dqblk(struct super_block *sb, int type, qid_t id,
> -		  struct if_dqblk *di)
> +		  struct fs_disk_quota *di)
>  {
>  	struct dquot *dquot;
>  	int rc;
>  
> +	if (!sb_has_quota_active(sb, type))
> +		return -ESRCH;
> +
  This is unnecessary...

>  	dquot = dqget(sb, id, type);
>  	if (!dquot) {
>  		rc = -ESRCH;
> 
								Honza
-- 
Jan Kara <jack@xxxxxxx>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux