block: add polled wakeup task helper
authorJens Axboe <axboe@kernel.dk>
Wed, 14 Nov 2018 04:16:54 +0000 (21:16 -0700)
committerJens Axboe <axboe@kernel.dk>
Fri, 16 Nov 2018 15:34:30 +0000 (08:34 -0700)
commit0619317ff8baa2da9238191ad5167ed3618c16d9
treebabd22e62aad323bd61539be388620b48a0d1f7c
parente504545446e4be916b170f159b6495c352a2b5a5
block: add polled wakeup task helper

If we're polling for IO on a device that doesn't use interrupts, then
IO completion loop (and wake of task) is done by submitting task itself.
If that is the case, then we don't need to enter the wake_up_process()
function, we can simply mark ourselves as TASK_RUNNING.

Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/block_dev.c
fs/iomap.c
include/linux/blkdev.h
mm/page_io.c