Now the per-host dedicated admin queue is ready, so use this queue to
send admin commands only.

Cc: Alan Stern <[email protected]>
Cc: Christoph Hellwig <[email protected]>
Cc: Bart Van Assche <[email protected]>
Cc: Jianchao Wang <[email protected]>
Cc: Hannes Reinecke <[email protected]>
Cc: Johannes Thumshirn <[email protected]>
Cc: Adrian Hunter <[email protected]>
Cc: "James E.J. Bottomley" <[email protected]>
Cc: "Martin K. Petersen" <[email protected]>
Cc: [email protected]
Signed-off-by: Ming Lei <[email protected]>
---
 drivers/scsi/scsi_lib.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index 87a88094b1eb..1e75515cc7ba 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -279,14 +279,14 @@ int __scsi_execute(struct scsi_device *sdev, const 
unsigned char *cmd,
        struct scsi_request *rq;
        int ret = DRIVER_ERROR << 24;
 
-       req = blk_get_request(sdev->request_queue,
+       req = blk_get_request(sdev->host->admin_q,
                        data_direction == DMA_TO_DEVICE ?
                        REQ_OP_SCSI_OUT : REQ_OP_SCSI_IN, BLK_MQ_REQ_PREEMPT);
        if (IS_ERR(req))
                return ret;
        rq = scsi_req(req);
 
-       if (bufflen &&  blk_rq_map_kern(sdev->request_queue, req,
+       if (bufflen &&  blk_rq_map_kern(req->q, req,
                                        buffer, bufflen, GFP_NOIO))
                goto out;
 
-- 
2.9.5

Reply via email to