summaryrefslogtreecommitdiffstats
path: root/block/blk-mq.h
diff options
context:
space:
mode:
authorJens Axboe <axboe@fb.com>2014-12-22 14:04:42 -0700
committerJens Axboe <axboe@fb.com>2014-12-31 09:39:16 -0700
commitaed3ea94bdd2ac0a21ed0103d34097e202ee77f6 (patch)
treee432ae8b2224a4172e4c91350b0135b14c587442 /block/blk-mq.h
parent2b25d981790b830f0e045881386866b970bf9066 (diff)
downloadlinux-aed3ea94bdd2ac0a21ed0103d34097e202ee77f6.tar.bz2
block: wake up waiters when a queue is marked dying
If it's dying, we can't expect new request to complete and come in an wake up other tasks waiting for requests. So after we have marked it as dying, wake up everybody currently waiting for a request. Once they wake, they will retry their allocation and fail appropriately due to the state of the queue. Tested-by: Keith Busch <keith.busch@intel.com> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-mq.h')
-rw-r--r--block/blk-mq.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/block/blk-mq.h b/block/blk-mq.h
index 206230e64f79..4f4f943c22c3 100644
--- a/block/blk-mq.h
+++ b/block/blk-mq.h
@@ -32,6 +32,7 @@ void blk_mq_free_queue(struct request_queue *q);
void blk_mq_clone_flush_request(struct request *flush_rq,
struct request *orig_rq);
int blk_mq_update_nr_requests(struct request_queue *q, unsigned int nr);
+void blk_mq_wake_waiters(struct request_queue *q);
/*
* CPU hotplug helpers