From patchwork Mon Aug 9 14:29:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Garry X-Patchwork-Id: 493873 Delivered-To: patch@linaro.org Received: by 2002:a05:6638:396:0:0:0:0 with SMTP id y22csp2977198jap; Mon, 9 Aug 2021 07:38:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz3d15VDiH845ZWhRZc2gxV15jvuYhbgjn81M16wlluJm7KgH6HP/ik5Z5J9lC+742XGbEc X-Received: by 2002:a92:6909:: with SMTP id e9mr210997ilc.231.1628519885386; Mon, 09 Aug 2021 07:38:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628519885; cv=none; d=google.com; s=arc-20160816; b=F8lMThKrGv2iLN4JvpVB8zhVJDcnYZ7NNnSwJoXV/wlj90Zpb7F9RBNQpGS6hzSeeZ sKCpRQneyin8H7YEZBAAzv/qrlpCo1M0JwiojDR9nlxiQ42x8gCCE2DMdzoZBnxX77yr O0v657lwdIzIC3WtC9anBfoETMMtGkEzHHnONPwdzcnFKZO1maFi2X+GNCg9YYlpgY0B U5iC81QD1PqxVNB0c6xrdQgWf6NqpuiykYsPon309uFpcigBAA3ntM1fnEAO1yDjjp3Q 6TtXHqRhDG+psQwMYNyXc+2bEA7a8KjH4q8/y4eVLb3U6xhh5rGS7cPTSEzw8hhusU7z wsCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from; bh=H+aFnM4mrLf5K8JkEUF1K+zWWITyKKqCklaFbeEkMpw=; b=YXkGYWBROEnpCohBPtT9KKrdiha7IWpmF4oVEmTKFdBl5bDwMS8CAPXZPUb07PAud7 TNo5X3+kUCd5HJoyE575qKKXfP7CHjM3tmaIa5iKxNXI20Nxtri0tBtU+odxkURQzAX7 7JearNnbd2GwQveLZqxTjWuF8IR7GdQqvDGRPpeNjgpVvUjurasD532dKW0BAdALhwf/ A/raYsizLj17eHuRHuZQhThEptxX4TXNLM8IMEnxMwZKKTHnH91EERTtulCFzqgTOgke S3eEZWzdritD1ZOsuLbEVUzmyrQs+qIIoLCIBGFUXD+HYhNOoal1RTLo+dLbDCMkuqiv XApQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r17si21191782iov.104.2021.08.09.07.38.05 for ; Mon, 09 Aug 2021 07:38:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235478AbhHIOiO (ORCPT ); Mon, 9 Aug 2021 10:38:14 -0400 Received: from frasgout.his.huawei.com ([185.176.79.56]:3615 "EHLO frasgout.his.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235268AbhHIOgP (ORCPT ); Mon, 9 Aug 2021 10:36:15 -0400 Received: from fraeml711-chm.china.huawei.com (unknown [172.18.147.200]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4Gjz9m3Dlnz6C997; Mon, 9 Aug 2021 22:34:20 +0800 (CST) Received: from lhreml724-chm.china.huawei.com (10.201.108.75) by fraeml711-chm.china.huawei.com (10.206.15.60) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.8; Mon, 9 Aug 2021 16:34:50 +0200 Received: from localhost.localdomain (10.69.192.58) by lhreml724-chm.china.huawei.com (10.201.108.75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Mon, 9 Aug 2021 15:34:47 +0100 From: John Garry To: , , CC: , , , , , , John Garry Subject: [PATCH v2 09/11] scsi: Set blk_mq_ops.init_request_no_hctx Date: Mon, 9 Aug 2021 22:29:36 +0800 Message-ID: <1628519378-211232-10-git-send-email-john.garry@huawei.com> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1628519378-211232-1-git-send-email-john.garry@huawei.com> References: <1628519378-211232-1-git-send-email-john.garry@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.69.192.58] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To lhreml724-chm.china.huawei.com (10.201.108.75) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org The hctx_idx argument is not used in scsi_mq_init_request(), so set as the blk_mq_ops.init_request_no_hctx callback instead. Signed-off-by: John Garry --- drivers/scsi/scsi_lib.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.26.2 diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index 7456a26aef51..6ea4d0847970 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c @@ -1738,7 +1738,7 @@ static enum blk_eh_timer_return scsi_timeout(struct request *req, } static int scsi_mq_init_request(struct blk_mq_tag_set *set, struct request *rq, - unsigned int hctx_idx, unsigned int numa_node) + unsigned int numa_node) { struct Scsi_Host *shost = set->driver_data; struct scsi_cmnd *cmd = blk_mq_rq_to_pdu(rq); @@ -1856,7 +1856,7 @@ static const struct blk_mq_ops scsi_mq_ops_no_commit = { #ifdef CONFIG_BLK_DEBUG_FS .show_rq = scsi_show_rq, #endif - .init_request = scsi_mq_init_request, + .init_request_no_hctx = scsi_mq_init_request, .exit_request = scsi_mq_exit_request, .initialize_rq_fn = scsi_initialize_rq, .cleanup_rq = scsi_cleanup_rq, @@ -1886,7 +1886,7 @@ static const struct blk_mq_ops scsi_mq_ops = { #ifdef CONFIG_BLK_DEBUG_FS .show_rq = scsi_show_rq, #endif - .init_request = scsi_mq_init_request, + .init_request_no_hctx = scsi_mq_init_request, .exit_request = scsi_mq_exit_request, .initialize_rq_fn = scsi_initialize_rq, .cleanup_rq = scsi_cleanup_rq,