summaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2014-02-07 10:22:37 -0800
committerJens Axboe <axboe@fb.com>2014-02-07 11:58:54 -0700
commit6f5ba581c0d3ba0a76fe138123c1c2817ffcbeb1 (patch)
tree48570824d90e7290ae71046b9824e2edfd992b2b /block
parent72a0a36e2854a6eadb4cf2561858f613f9cd4639 (diff)
downloadtalos-obmc-linux-6f5ba581c0d3ba0a76fe138123c1c2817ffcbeb1.tar.gz
talos-obmc-linux-6f5ba581c0d3ba0a76fe138123c1c2817ffcbeb1.zip
blk-mq: divert __blk_put_request for MQ ops
__blk_put_request needs to call into the blk-mq code just like blk_put_request. As we don't have the queue lock in this case both end up calling the same function. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block')
-rw-r--r--block/blk-core.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/block/blk-core.c b/block/blk-core.c
index c00e0bdeab4a..06636f3ad424 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -1278,6 +1278,11 @@ void __blk_put_request(struct request_queue *q, struct request *req)
if (unlikely(!q))
return;
+ if (q->mq_ops) {
+ blk_mq_free_request(req);
+ return;
+ }
+
blk_pm_put_request(req);
elv_completed_request(q, req);
OpenPOWER on IntegriCloud