summaryrefslogtreecommitdiffstats
path: root/fs/f2fs/file.c
diff options
context:
space:
mode:
authorJaegeuk Kim <jaegeuk.kim@samsung.com>2013-06-10 09:17:01 +0900
committerJaegeuk Kim <jaegeuk.kim@samsung.com>2013-06-14 09:04:43 +0900
commitb3783873cc2214542d3da9a1aa800b20919d5889 (patch)
tree7b2e4f8eafd726c9c97bfde832a0178c840815a7 /fs/f2fs/file.c
parentd7cc950b4c910e4440485be784493880a0d09086 (diff)
downloadblackbird-obmc-linux-b3783873cc2214542d3da9a1aa800b20919d5889.tar.gz
blackbird-obmc-linux-b3783873cc2214542d3da9a1aa800b20919d5889.zip
f2fs: avoid freqeunt write_inode calls
If update_inode is called, we don't need to do write_inode. So, let's use a *dirty* flag for each inode. Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
Diffstat (limited to 'fs/f2fs/file.c')
-rw-r--r--fs/f2fs/file.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c
index 2f649b848521..fda226ff1849 100644
--- a/fs/f2fs/file.c
+++ b/fs/f2fs/file.c
@@ -147,6 +147,7 @@ int f2fs_sync_file(struct file *file, loff_t start, loff_t end, int datasync)
} else {
/* if there is no written node page, write its inode page */
while (!sync_node_pages(sbi, inode->i_ino, &wbc)) {
+ mark_inode_dirty_sync(inode);
ret = f2fs_write_inode(inode, NULL);
if (ret)
goto out;
OpenPOWER on IntegriCloud