diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/f2fs/gc.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/f2fs/gc.c b/fs/f2fs/gc.c index 943a31d..075ea1e 100644 --- a/fs/f2fs/gc.c +++ b/fs/f2fs/gc.c @@ -423,6 +423,12 @@ next_step: if (IS_ERR(node_page)) continue; + /* block may become invalid during get_node_page */ + if (check_valid_map(sbi, segno, off) == 0) { + f2fs_put_page(node_page, 1); + continue; + } + /* set page dirty and write it */ if (gc_type == FG_GC) { f2fs_wait_on_page_writeback(node_page, NODE); |