summaryrefslogtreecommitdiff
path: root/fs/quota.c
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2008-09-30 17:53:37 +0200
committerMark Fasheh <mfasheh@suse.com>2009-01-05 08:36:57 -0800
commitca785ec66b991e9ca74dd9840fc014487ad095e1 (patch)
tree271c7b36123e9c16f455ecd96352d24ecd20423c /fs/quota.c
parentdcb30695f2cac86b71417629a6fe8042b4fe2ab2 (diff)
downloadlinux-3.10-ca785ec66b991e9ca74dd9840fc014487ad095e1.tar.gz
linux-3.10-ca785ec66b991e9ca74dd9840fc014487ad095e1.tar.bz2
linux-3.10-ca785ec66b991e9ca74dd9840fc014487ad095e1.zip
quota: Introduce DQUOT_QUOTA_SYS_FILE flag
If filesystem can handle quota files as system files hidden from users, we can skip a lot of cache invalidation, syncing, inode flags setting etc. when turning quotas on, off and quota_sync. Allow filesystem to indicate that it is hiding quota files from users by DQUOT_QUOTA_SYS_FILE flag. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Diffstat (limited to 'fs/quota.c')
-rw-r--r--fs/quota.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/quota.c b/fs/quota.c
index 8678d9f35ee..4a8c94f05f7 100644
--- a/fs/quota.c
+++ b/fs/quota.c
@@ -160,6 +160,9 @@ static void quota_sync_sb(struct super_block *sb, int type)
int cnt;
sb->s_qcop->quota_sync(sb, type);
+
+ if (sb_dqopt(sb)->flags & DQUOT_QUOTA_SYS_FILE)
+ return;
/* This is not very clever (and fast) but currently I don't know about
* any other simple way of getting quota data to disk and we must get
* them there for userspace to be visible... */