summaryrefslogtreecommitdiff
path: root/block/blk-exec.c
diff options
context:
space:
mode:
Diffstat (limited to 'block/blk-exec.c')
-rw-r--r--block/blk-exec.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/block/blk-exec.c b/block/blk-exec.c
index 73b8a701ae6d..27e4d82564ed 100644
--- a/block/blk-exec.c
+++ b/block/blk-exec.c
@@ -80,8 +80,14 @@ void blk_execute_rq_nowait(struct request_queue *q, struct gendisk *bd_disk,
}
__elv_add_request(q, rq, where);
- __blk_run_queue(q);
- spin_unlock_irq(q->queue_lock);
+
+ if (q->mq_ops) {
+ spin_unlock_irq(q->queue_lock);
+ blk_mq_run_hw_queues(q, false);
+ } else {
+ __blk_run_queue(q);
+ spin_unlock_irq(q->queue_lock);
+ }
}
EXPORT_SYMBOL_GPL(blk_execute_rq_nowait);