summaryrefslogtreecommitdiff
path: root/fs/f2fs
diff options
context:
space:
mode:
authorChao Yu <yuchao0@huawei.com>2017-08-18 16:20:33 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2017-08-29 10:02:57 -0700
commit0adf6a1b796777f5d19a9b7442172016aeb8020a (patch)
tree39b78ea4e5f2f1abb03974f81e0c77c070bf4290 /fs/f2fs
parent84a23fbe96b4e307eb749046a74515329119b08d (diff)
f2fs: trigger normal fsync for non-atomic_write file
If file was not opened with atomic write mode, but user uses atomic write ioctl to fsync datas, in the flow, we should not fsync that file with atomic write mode. Fixes: 608514deba38 ("f2fs: set fsync mark only for the last dnode") Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs')
-rw-r--r--fs/f2fs/file.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c
index 8f0d32a57b52..d74f1a9104a3 100644
--- a/fs/f2fs/file.c
+++ b/fs/f2fs/file.c
@@ -1683,7 +1683,7 @@ static int f2fs_ioc_commit_atomic_write(struct file *filp)
stat_dec_atomic_write(inode);
}
} else {
- ret = f2fs_do_sync_file(filp, 0, LLONG_MAX, 0, true);
+ ret = f2fs_do_sync_file(filp, 0, LLONG_MAX, 0, false);
}
err_out:
inode_unlock(inode);