f2fs: skip unnecessary node writes during fsync
authorJaegeuk Kim <jaegeuk.kim@samsung.com>
Thu, 20 Mar 2014 12:52:53 +0000 (21:52 +0900)
committerIan Chang <ianc@nvidia.com>
Wed, 27 Jan 2016 10:03:55 +0000 (18:03 +0800)
commit065cdb645b4db88f18db8124845d899ff1d6fe2f
treeef60c90a45ddbce124f8d18dd7118e67570b1a5a
parentd8d9fc7d0d80feca5d256a424137fcbdf25dc856
f2fs: skip unnecessary node writes during fsync

If multiple redundant fsync calls are triggered, we don't need to write its
node pages with fsync mark continuously.

So, this patch adds FI_NEED_FSYNC to track whether the latest node block is
written with the fsync mark or not.
If the mark was set, a new fsync doesn't need to write a node block.
Otherwise, we should do a new node block with the mark for roll-forward
recovery.

Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>

Conflicts:
fs/f2fs/node.c

Change-Id: If1f221ab88a717847ef8cfd41d0b8b6df9dd1fd2
fs/f2fs/f2fs.h
fs/f2fs/file.c
fs/f2fs/node.c
fs/f2fs/node.h