Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3a7ea2c4 authored by Jens Axboe's avatar Jens Axboe
Browse files

scsi: provide mq_ops->busy() hook



Only the SCSI legacy path provides a way to check if target is
currently busy, provide the same for the MQ path.

Cc: linux-scsi@vger.kernel.org
Reviewed-by: default avatarHannes Reinecke <hare@suse.com>
Tested-by: default avatarMing Lei <ming.lei@redhat.com>
Reviewed-by: default avatarOmar Sandoval <osandov@fb.com>
Acked-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 9ba20527
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1675,6 +1675,11 @@ static int scsi_lld_busy(struct request_queue *q)
	return 0;
}

static bool scsi_mq_lld_busy(struct request_queue *q)
{
	return scsi_lld_busy(q);
}

/*
 * Kill a request for a dead device
 */
@@ -2326,6 +2331,7 @@ static const struct blk_mq_ops scsi_mq_ops = {
	.init_request	= scsi_mq_init_request,
	.exit_request	= scsi_mq_exit_request,
	.initialize_rq_fn = scsi_initialize_rq,
	.busy		= scsi_mq_lld_busy,
	.map_queues	= scsi_map_queues,
};