quota: explicitly set ->dq_op and ->s_qcop

Only set the quota operation vectors if the filesystem actually supports
quota instead of doing it for all filesystems in alloc_super().

[Jan Kara: Export dquot_operations and vfs_quotactl_ops]

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jan Kara <jack@suse.cz>
This commit is contained in:
Christoph Hellwig
2010-05-19 07:16:44 -04:00
committed by Jan Kara
parent 307ae18a56
commit 123e9caf1e
7 changed files with 22 additions and 15 deletions

View File

@@ -1948,7 +1948,11 @@ static int udf_fill_super(struct super_block *sb, void *options, int silent)
/* Fill in the rest of the superblock */
sb->s_op = &udf_sb_ops;
sb->s_export_op = &udf_export_ops;
sb->dq_op = NULL;
#ifdef CONFIG_QUOTA
sb->s_qcop = &vfs_quotactl_ops;
sb->dq_op = NULL; /* &dquot_operations */
#endif
sb->s_dirt = 0;
sb->s_magic = UDF_SUPER_MAGIC;
sb->s_time_gran = 1000;