f2fs: use wq_has_sleeper for cp_wait wait_queue
Subsystems (2)
Jaegeuk Kim
maintainerPATCH 1/1 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 Jaegeuk Kim <[email protected]>
--- fs/f2fs/data.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
fs/f2fs/data.c +1 -2
@@ -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);
Signature · 1 line
2.6.3