Commit d6cc464c authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Jens Axboe
Browse files

blk-mq: short cut the IPI path in blk_mq_force_complete_rq for !SMP



Let the compile optimize out the entire IPI path, given that we are
obviously not going to use it.

Reviewed-by: default avatarDaniel Wagner <dwagner@suse.de>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 6aab1da6
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -727,7 +727,8 @@ void blk_mq_force_complete_rq(struct request *rq)
		return;
	}

	if (!test_bit(QUEUE_FLAG_SAME_COMP, &q->queue_flags)) {
	if (!IS_ENABLED(CONFIG_SMP) ||
	    !test_bit(QUEUE_FLAG_SAME_COMP, &q->queue_flags)) {
		q->mq_ops->complete(rq);
		return;
	}