summaryrefslogtreecommitdiffstats
path: root/fs/f2fs
diff options
context:
space:
mode:
authorChao Yu <yuchao0@huawei.com>2017-08-23 18:23:25 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2017-08-29 10:05:42 -0700
commit774e1b78a0f90a7e81f7a23d9ebfa8b8233c1ffa (patch)
tree7091832b386af301fc273505a7f7721f1dc4e0e7 /fs/f2fs
parent73ac2f4e8256b9605c84364011322f015b31f499 (diff)
downloadlinux-774e1b78a0f90a7e81f7a23d9ebfa8b8233c1ffa.tar.bz2
f2fs: trigger fdatasync for non-atomic_write file
Sqlite only cares about synchronization of file data instead of other data unrelated attribute of inode, so in commit flow, call fdatasync is enough. 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 d74f1a9104a3..63e394907808 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, false);
+ ret = f2fs_do_sync_file(filp, 0, LLONG_MAX, 1, false);
}
err_out:
inode_unlock(inode);