aboutsummaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorYunlei He <heyunlei@huawei.com>2016-02-23 12:07:56 +0800
committerMister Oyster <oysterized@gmail.com>2017-04-13 12:33:08 +0200
commit09635f3b8f7614254c0ce9f51a56cc0e29c4761d (patch)
tree56864c9ecfff631ab20a7c8283fbe1b78c57b0d9 /kernel
parentc173fa4f4ca710bf5aae9d70b1fcb7e7595a06d9 (diff)
f2fs: avoid hungtask problem caused by losing wake_up
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: Yunlei He <heyunlei@huawei.com> Signed-off-by: Biao He <hebiao6@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/sched/core.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 19d98e5f1..007e48eee 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -5088,6 +5088,7 @@ long __sched io_schedule_timeout(long timeout)
delayacct_blkio_end();
return ret;
}
+EXPORT_SYMBOL(io_schedule_timeout);
/**
* sys_sched_get_priority_max - return maximum RT priority.