summaryrefslogtreecommitdiffstats
path: root/block/blk-core.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2014-04-16 18:48:08 +0200
committerJens Axboe <axboe@fb.com>2014-04-16 22:15:25 +0200
commit70f4db639c5b2479e08657392cbf3ba3cceea11c (patch)
tree58a5acc839c2d0dd73436fcd6a95c8fe50bbccff /block/blk-core.c
parentblk-mq: add async parameter to blk_mq_start_stopped_hw_queues (diff)
downloadlinux-70f4db639c5b2479e08657392cbf3ba3cceea11c.tar.xz
linux-70f4db639c5b2479e08657392cbf3ba3cceea11c.zip
blk-mq: add blk_mq_delay_queue
Add a blk-mq equivalent to blk_delay_queue so that the scsi layer can ask to be kicked again after a delay. Signed-off-by: Christoph Hellwig <hch@lst.de> Modified by me to kill the unnecessary preempt disable/enable in the delayed workqueue handler. Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-core.c')
-rw-r--r--block/blk-core.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/block/blk-core.c b/block/blk-core.c
index ae6227fd07aa..90b6e63b8769 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -251,8 +251,10 @@ void blk_sync_queue(struct request_queue *q)
struct blk_mq_hw_ctx *hctx;
int i;
- queue_for_each_hw_ctx(q, hctx, i)
- cancel_delayed_work_sync(&hctx->delayed_work);
+ queue_for_each_hw_ctx(q, hctx, i) {
+ cancel_delayed_work_sync(&hctx->run_work);
+ cancel_delayed_work_sync(&hctx->delay_work);
+ }
} else {
cancel_delayed_work_sync(&q->delay_work);
}