From: Chao Yu Date: Mon, 7 Aug 2017 08:37:59 +0000 (+0800) Subject: f2fs: avoid unneeded sync on quota file X-Git-Tag: v4.14-rc1~46^2~35 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9a20d391cd099d547c0f17626bf6f13e06da519a;p=thirdparty%2Flinux.git f2fs: avoid unneeded sync on quota file We only need to sync quota file with appointed quota type instead of all types in f2fs_quota_{on,off}. Signed-off-by: Chao Yu Signed-off-by: Jaegeuk Kim --- diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index ca340d84f8c23..54b8ff4c6fc9d 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -1176,7 +1176,7 @@ static int f2fs_quota_on(struct super_block *sb, int type, int format_id, struct inode *inode; int err; - err = f2fs_quota_sync(sb, -1); + err = f2fs_quota_sync(sb, type); if (err) return err; @@ -1204,7 +1204,7 @@ static int f2fs_quota_off(struct super_block *sb, int type) if (!inode || !igrab(inode)) return dquot_quota_off(sb, type); - f2fs_quota_sync(sb, -1); + f2fs_quota_sync(sb, type); err = dquot_quota_off(sb, type); if (err)