diff options
| author | Chao Yu <yuchao0@huawei.com> | 2018-06-04 23:20:51 +0800 |
|---|---|---|
| committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2018-07-08 17:49:47 -0700 |
| commit | d400752f547f8aea87260885fcdceed3a58e9072 (patch) | |
| tree | f34ed59b7653c09263f4c10355a74ee68fd4d411 /include/linux/overflow.h | |
| parent | 853e7339b634660b951d9892e036faf225cf1187 (diff) | |
f2fs: fix to clear FI_VOLATILE_FILE correctly
Thread A Thread B
- f2fs_release_file
- clear_inode_flag(FI_VOLATILE_FILE)
- wb_writeback
- writeback_sb_inodes
- __writeback_single_inode
- do_writepages
- f2fs_write_data_pages
- __write_data_page
all volatile file's pages
are writebacked to storage
- set_inode_flag(FI_DROP_CACHE)
- filemap_fdatawrite
There is a hole that mm can flush all dirty pages of volatile file as
inode is not tagged with both FI_VOLATILE_FILE and FI_DROP_CACHE flags,
we should never writeback the page #0 and also it's unneeded to writeback
other pages.
This patch adjusts to relocate clear_inode_flag(FI_VOLATILE_FILE), so that
FI_VOLATILE_FILE flag can be remained before all dirty pages were dropped
to avoid issue.
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'include/linux/overflow.h')
0 files changed, 0 insertions, 0 deletions
