diff options
| author | Chao Yu <yuchao0@huawei.com> | 2017-08-23 18:23:25 +0800 |
|---|---|---|
| committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2017-09-21 14:15:14 -0700 |
| commit | 077e22bf7a87013157dca27ea9e7ff3adcd75385 (patch) | |
| tree | 61885394b9e90e082fb49602cc46791e48bba3a0 | |
| parent | 0520ca37ef89ae0ce3679da7616b7a66a0cfa774 (diff) | |
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>
| -rw-r--r-- | fs/f2fs/file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c index 1c3dffc987b1..6c2ebe91afeb 100644 --- a/fs/f2fs/file.c +++ b/fs/f2fs/file.c @@ -1660,7 +1660,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); |
