提交 7c506896 编写于 作者: J Jaegeuk Kim

f2fs: use wq_has_sleeper for cp_wait wait_queue

We need to use wq_has_sleeper including smp_mb to consider cp_wait concurrency.
Signed-off-by: NJaegeuk Kim <jaegeuk@kernel.org>
上级 688159b6
......@@ -74,8 +74,7 @@ static void f2fs_write_end_io(struct bio *bio)
dec_page_count(sbi, F2FS_WRITEBACK);
}
if (!get_pages(sbi, F2FS_WRITEBACK) &&
!list_empty(&sbi->cp_wait.task_list))
if (!get_pages(sbi, F2FS_WRITEBACK) && wq_has_sleeper(&sbi->cp_wait))
wake_up(&sbi->cp_wait);
bio_put(bio);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册