diff options
author | Jaegeuk Kim <jaegeuk@kernel.org> | 2015-05-01 02:00:33 +0200 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2015-05-29 00:41:37 +0200 |
commit | 43f3eae1d3b1de6a4f7e39ef9c363ec6f8b9c8d4 (patch) | |
tree | 32f273bfd14351cf7350a79d080483db76a7cf31 /fs/f2fs/gc.c | |
parent | f2fs: fix counting the number of inline_data inodes (diff) | |
download | linux-43f3eae1d3b1de6a4f7e39ef9c363ec6f8b9c8d4.tar.xz linux-43f3eae1d3b1de6a4f7e39ef9c363ec6f8b9c8d4.zip |
f2fs: split find_data_page according to specific purposes
This patch splits find_data_page as follows.
1. f2fs_gc
- use get_read_data_page() with read only
2. find_in_level
- use find_data_page without locked page
3. truncate_partial_page
- In the case cache_only mode, just drop cached page.
- Ohterwise, use get_lock_data_page() and guarantee to truncate
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/gc.c')
-rw-r--r-- | fs/f2fs/gc.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/f2fs/gc.c b/fs/f2fs/gc.c index 1bd11f017a23..2e2afebd9d0f 100644 --- a/fs/f2fs/gc.c +++ b/fs/f2fs/gc.c @@ -607,9 +607,8 @@ next_step: continue; start_bidx = start_bidx_of_node(nofs, F2FS_I(inode)); - - data_page = find_data_page(inode, - start_bidx + ofs_in_node, false); + data_page = get_read_data_page(inode, + start_bidx + ofs_in_node, READA); if (IS_ERR(data_page)) { iput(inode); continue; |