Skip to content
  • Yunlei He's avatar
    f2fs: avoid hungtask problem caused by losing wake_up · 0ff21646
    Yunlei He authored
    
    
    The D state of wait_on_all_pages_writeback should be waken by
    function f2fs_write_end_io when all writeback pages have been
    succesfully written to device. It's possible that wake_up comes
    between get_pages and io_schedule. Maybe in this case it will
    lost wake_up and still in D state even if all pages have been
    write back to device, and finally, the whole system will be into
    the hungtask state.
    
                    if (!get_pages(sbi, F2FS_WRITEBACK))
                             break;
    					<---------  wake_up
                    io_schedule();
    
    Signed-off-by: default avatarYunlei He <heyunlei@huawei.com>
    Signed-off-by: default avatarBiao He <hebiao6@huawei.com>
    Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
    0ff21646