mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
block: add a poll_fn callback to struct request_queue
That we we can also poll non blk-mq queues. Mostly needed for the NVMe multipath code, but could also be useful elsewhere. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Hannes Reinecke <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
8ddcd65325
commit
ea435e1b93
8 changed files with 25 additions and 16 deletions
|
|
@ -486,7 +486,7 @@ static struct bio *dio_await_one(struct dio *dio)
|
|||
dio->waiter = current;
|
||||
spin_unlock_irqrestore(&dio->bio_lock, flags);
|
||||
if (!(dio->iocb->ki_flags & IOCB_HIPRI) ||
|
||||
!blk_mq_poll(dio->bio_disk->queue, dio->bio_cookie))
|
||||
!blk_poll(dio->bio_disk->queue, dio->bio_cookie))
|
||||
io_schedule();
|
||||
/* wake up sets us TASK_RUNNING */
|
||||
spin_lock_irqsave(&dio->bio_lock, flags);
|
||||
|
|
|
|||
Loading…
Reference in a new issue