From patchwork Thu Dec 28 20:33:13 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Madhani, Himanshu" X-Patchwork-Id: 10135869 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 426F260318 for ; Thu, 28 Dec 2017 20:34:22 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 349082B1F6 for ; Thu, 28 Dec 2017 20:34:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 296AC2B7EC; Thu, 28 Dec 2017 20:34:22 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8F3FD2B1F6 for ; Thu, 28 Dec 2017 20:34:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755297AbdL1UeU (ORCPT ); Thu, 28 Dec 2017 15:34:20 -0500 Received: from mail-by2nam03on0066.outbound.protection.outlook.com ([104.47.42.66]:2085 "EHLO NAM03-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754413AbdL1UeE (ORCPT ); Thu, 28 Dec 2017 15:34:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=0VnoK6MzK5/svo8Dk5EFDpPEdlxfpKxXvF2wLxWU/mk=; b=gQ+3xc/Kk7Oiuu5+3OmJMIiNCa4Jy9MFqaKHnus3PTl+pK7g4NyjCL2vAH5/Mk+sr9v+OIcLY+x4xmQZX5V6MdLYjfuwdEtVAxp6sYNiZhOigRo/dxhSC1fvoPnYntl8JoL2/eQUNM1AnORpZ4lzDYYF7XqtlzZEgJR5VeDEVEM= Received: from CO2PR07CA0066.namprd07.prod.outlook.com (2603:10b6:100::34) by SN4PR0701MB3823.namprd07.prod.outlook.com (2603:10b6:803:4f::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.323.15; Thu, 28 Dec 2017 20:34:02 +0000 Received: from BN1BFFO11OLC002.protection.gbl (2a01:111:f400:7c10::1:169) by CO2PR07CA0066.outlook.office365.com (2603:10b6:100::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.366.8 via Frontend Transport; Thu, 28 Dec 2017 20:34:02 +0000 Authentication-Results: spf=permerror (sender IP is 50.232.66.26) smtp.mailfrom=cavium.com; vger.kernel.org; dkim=none (message not signed) header.d=none; vger.kernel.org; dmarc=none action=none header.from=cavium.com; Received-SPF: PermError (protection.outlook.com: domain of cavium.com used an invalid SPF mechanism) Received: from CAEXCH02.caveonetworks.com (50.232.66.26) by BN1BFFO11OLC002.mail.protection.outlook.com (10.58.145.13) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.20.345.12 via Frontend Transport; Thu, 28 Dec 2017 20:33:41 +0000 Received: from dut1171.mv.qlogic.com (172.29.51.171) by CAEXCH02.caveonetworks.com (10.17.4.29) with Microsoft SMTP Server id 14.2.347.0; Thu, 28 Dec 2017 12:33:49 -0800 Received: from dut1171.mv.qlogic.com (localhost [127.0.0.1]) by dut1171.mv.qlogic.com (8.14.7/8.14.7) with ESMTP id vBSKXk1n002803; Thu, 28 Dec 2017 12:33:46 -0800 Received: (from root@localhost) by dut1171.mv.qlogic.com (8.14.7/8.14.7/Submit) id vBSKXk1c002802; Thu, 28 Dec 2017 12:33:46 -0800 From: Himanshu Madhani To: , CC: , Subject: [PATCH v2 05/37] qla2xxx: Chip reset uses wrong lock during IO flush. Date: Thu, 28 Dec 2017 12:33:13 -0800 Message-ID: <20171228203345.2702-6-himanshu.madhani@cavium.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20171228203345.2702-1-himanshu.madhani@cavium.com> References: <20171228203345.2702-1-himanshu.madhani@cavium.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:50.232.66.26; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(376002)(346002)(39860400002)(39380400002)(396003)(2980300002)(448002)(189003)(199004)(76176011)(86362001)(478600001)(316002)(51416003)(80596001)(2906002)(8936002)(50466002)(36756003)(48376002)(6666003)(50226002)(59450400001)(305945005)(5660300001)(356003)(106466001)(1076002)(2950100002)(72206003)(110136005)(4326008)(47776003)(69596002)(85326001)(81156014)(87636003)(81166006)(42186006)(8676002)(16586007)(54906003); DIR:OUT; SFP:1101; SCL:1; SRVR:SN4PR0701MB3823; H:CAEXCH02.caveonetworks.com; FPR:; SPF:PermError; PTR:50-232-66-26-static.hfc.comcastbusiness.net; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1BFFO11OLC002; 1:Vio7xsENWfY1O9PhOToigUUMVcqDlIXSG1IcAuEXj0SvuqxgDB3kDv7Gkw56WfHPnZLqEMc4fLbSk8P0Mg72Kby8sT1Kpx0Nj/lQ0acEABvtaaO5Bb+8FcRVafWiA5FY X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 96494c07-e62e-4ce2-066f-08d54e3248d2 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(5600026)(4604075)(2017052603307)(7153060); SRVR:SN4PR0701MB3823; X-Microsoft-Exchange-Diagnostics: 1; SN4PR0701MB3823; 3:4jOQ7AOtGQCHALs8TWJ7U0ui3bzhwChU8NbUFpjHqYo61/F/NeQfUwMjCMBBZRdtSa9jd7QyiXE7zMHTNqcksa8cFQnYRwGcdbZEigUfEXbM8OKRMHsnc4WIvr5nE5GCrPXW+Pk/1vqqhg98FFLp9T4w4EF+48qNJoXar/gR7Hgh2vzjPQbY8MJ7kLEtb4KnvARdkMCrfqxPWmCPy4TOKemDx4dqY8eOjOBfGlwStEka1sBZAIUfKp53kdC6j+D6dJGTO9rG2xLTzlAB+Scjbmsq0hqTKumSrFgWhXpP1do4oub4NRPzrdWfCD0GbftA6hcUCh+5aTq1ZwE8Qwzwuw==; 25:+ialZJSiSwq/FfDTiyaXrPS+RciMT+7uUflscrKrZo/zsNe/JAETUpfvLwEg9ZCEGKA0dAS7UE6Pg5YBH9mok97qE/RNwzKjBbIjYeoqnuZV7t9NlE3+imv7F4s/US6czAUyhJsArbqoD8i0E4NjprOomHVocCfgicLOjYz40WEpGc0gi0t8yqPJExLZ3RjA9uL4NKw5cPgd22hivGlZBEBXTUXR7b1LfmF15GYoN1CPkZIkXDnjRTCiOatGPdc23e8CcHeUWKjqdpaizuVNT+JEMku4yRrGrox5ZYW9UakJt1nRNQ4XFFIKkf7X2tCAY7pw9zbgaKFMSV90pUVfvw==; 31:cB20u7RltFRFBsZ7Nut4Q+Ds7x6etG5xS59khb4y6Pfjj/LQASzT3CDKlVSKWXi7THFpP4Hent1oz7p+gSEDK8AcOgDr14gNskBY8y4iAjXAs3HSUIR0k+JdPC5e5jdqnDT49sSg5ylzuY3BosA4yMNW5h9qW23zWMmbiT+cwzUtY/b0S6HfWv260dINCmtsLBiF96IuHvpcjOnzRR8TiovwqkQZf6Ufk9aR0QCcpjU= X-MS-TrafficTypeDiagnostic: SN4PR0701MB3823: X-Microsoft-Exchange-Diagnostics: 1; SN4PR0701MB3823; 20:2Tp6UD11+qkPLSYYw2lf+u9QvF4WiI1UPTcLyD2AiCU6JSKarCrjDsrGwZTU2soRPqohm05BOr5+F2pWxIr2BTgwQHgPwhMZwwPqZvsll2NCqqJll0orf0FA43eb+uZU8qHFwfvSXII87R6/Ky7qor8LjDLT/w7Q8v5r6/Ksh1FwQVBUYUVLEGx6ufxt6Auh8xvi3OxP7rg6zbU7roMl5bRW/CRxMt40sMEb9DriZMyLHzDUajzT9eqY4mvQlRXg7RnVcr2CbtHhn9P0WIOnGfojMYbGlMWX/HI2UetbCq8gmSAhXmCRY1KroeBEB+U1idWfOIVBTPxd3MLODcxH8gZx/TPdSrpiySvMGIFTKlQSfOGjBsD+hn9Dt9aN0XjFmYn/rXIayxabBf0zNCSPWBfyzafEwMcZZDrw3Xk53dIrkD364ii4lKrAvMp4hA9NK/eiDCjGyMKRMIaBdKMmqj7vOqaD8Qt2+U5iEeUy/jPS2WF7SQNVkOjt/lxcFVAa; 4:ebc86vXfxrJWg7xNjNBNyL50lIxlJUWXdbZ4PkUIFHQFOA2eEs3seVGO3MyUENiAeZCz8OWKWmFKG9MVpxpU8w3ekzi8TCtgIL1+tDkU8lqL1AipQRQKJWguHqBSVQHYiIs8jdcKvdZMFaXkJl1UWEBOb0ixMUab8Ns8L2GMNd8XLZljTxMFzDkjeN2rGey9eyaLYLRPG1yFQoqlfXva4NWhlFFZ807AEv4/r1t36qMkysUoxYuz2GElHmft+TuUgLO41tDYjKdPvtWI4qM1KQ== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040470)(2401047)(5005006)(8121501046)(3002001)(10201501046)(3231023)(944501075)(93006095)(93001095)(6041268)(20161123564045)(20161123558120)(20161123562045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011); SRVR:SN4PR0701MB3823; BCL:0; PCL:0; RULEID:(100000803101)(100110400095); SRVR:SN4PR0701MB3823; X-Forefront-PRVS: 05352A48BE X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN4PR0701MB3823; 23:wOXMub7H52GP1AsPAeGC0AW1P/iqNcHo5H7Tnlv?= =?us-ascii?Q?92wSl7APN1Zb8oSFh6jS7ePACDYR9uX2zs+SAzABEcl5fNrudwE367YcbCgy?= =?us-ascii?Q?pU5P4LQ4lzOibQTeMimT0m8jL6LSFaILTplUVJ7uC/AO53viW4cQOOov7Hen?= =?us-ascii?Q?b5lElcWdFDjGxCraNwPPxsVH+SnvA4QRs4rmhK5V0K+D1l7jR/pXmlab1QNx?= =?us-ascii?Q?SX+gf9HILFvmPtvD9D0XUPky1Aq4u62OaFwgrFDxi4yuVooEpXKdiHJ9eCRn?= =?us-ascii?Q?86wPl+vEIQbQfKbFjzGze1OadnOMpmhSSY7SHSIic/qp7ViEYveuFwNxTBaT?= =?us-ascii?Q?z0+pTI9sve5kOlyYTJ30MBwdPLcz4RMyIfEqeiiFTn1aAggbrUe8+NbnQ2qk?= =?us-ascii?Q?/rtyNa/gII2wdQB8lVsd0FNb/OGuIRMxov+sbVBJCwH+7wPWcrU6fUXTacqY?= =?us-ascii?Q?niaKKQ7Qbn5Lw0HPtscRqU8tvc+q9P7WjUUJCsIToCO1tdAmyrB646A2KEqc?= =?us-ascii?Q?ZpEJaLju7zayzwTLgk14opoXjsjqldWZFa3txlGMBH60a2/rmPB0umAkO4Bo?= =?us-ascii?Q?50L2X/6GrY30HIvn2KEnPn5wPDLEHaxXN0GvsmeuBCkFLOZVxZrsb+WUIimo?= =?us-ascii?Q?yS4chTi/KzPW83DOvE1vLzADPr5kCFg4xnzMEgZ0xJzt9Jzgean1lREB8xOK?= =?us-ascii?Q?OPCWf/yt6V5h1ozF+eaB/zWuMgG27NdIOTkfHSmoCGh+HGgj0ILAZp4aAG9/?= =?us-ascii?Q?l2zROwo3kZcYC8bX7mQmcHzeisZ2hRUNy9k/gAqmEnVL5miivubtVoUV+hWK?= =?us-ascii?Q?ymI22m6EbVR1mFpO16JbHbbJh3AbrJgQ1qlw6lJB6HfAF2n5IZiW8pKM4UOp?= =?us-ascii?Q?9gfzhHaT7INSFoVG0VYmQ1FTRiDRHeeN3bt46KZ2+MNiiQPfI/aC/Q+xPlqz?= =?us-ascii?Q?md2W5dwYdaV9JFWGdX07OMbSHu/lknfj5u1GBkdPLnwqPUFCadensc0NwvCL?= =?us-ascii?Q?ddKAH1RslDkN3NaiOC8mQoZNV?= X-Microsoft-Exchange-Diagnostics: 1; SN4PR0701MB3823; 6:FlzVuELRlOHOnMUIAGAb/H+8cEP4t8g4sKPrecN18XMrXtbBnft+/ERx1iV5JQN0i7I0zayntFt5Ml63imKUNe1RWSNx7iIgOR/bTqVfvEBylQYelgEwP+7fNXRjwmN5OC/q8VbUxWLOqK1zg7CpOH0fFikYZPZs3eIG6DWINYQpJY8GvvtGrs+3yJD2YtLzDpODmvPeZC7X8htidAsyEOEtJDbrdkjFmEx8u54m2qwhAYrlOq+2znNKvwUgWqGK33h37a0CUzvafWSax9EFMf5x4neiCUyixCvYv1+NW5Pp3bLZxlZ0WbzJPpO/lyrCX8LismrPnck+YrM+HNgJJWRY4pfn8nLFxrI9r6Uxrvk=; 5:QvjWEQTLstOKnTdTkbWoHZSZof3PieP7npWQ47f8XiiSUwyCR4oUzxV42C45ylrjVKrgrm8hCiIoWbFNGWJSJLWveDHNDw9saq3783EQkJDzlbf68/hjXnbfCteNr8to5tr6F4PbtkvQtFVqfISk/cqO587F9t7K7xD7KRlnE60=; 24:c5pwE8niX2rSK366Ra3Bsz4/x1cnKcpy++r/Zi+uSvl6+WZksc/UdFw6zSIgZlnQMcq3WRcrdenQXqPTuyrl2B+z3/ooXifoGf6ke6waD00=; 7:nMW5wZXRDHR6JAU+C+ZiBCxJkcMWKm4m/Vl5tmoNcx4c7Zhu1RtE+gTh0Wh623sAxIT8ga0FGHM2ABrfa5R7u8r/sMUK1Fm53FBVEisBDG1yRQlLcao9DMVQYSYVMnWvpn8ItXTMTg+IywH/XUUDHvi5HjSnh0KQmGtwGWX8XyzsBsiqJsb6Ux6VKUDQWrxFSJkntJWf7XhyQKUTp3vCG/AoxHeiDQHodw9eXl2Xmfnys8l5c/ALKC868I2rqAAK SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Dec 2017 20:33:41.6260 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 96494c07-e62e-4ce2-066f-08d54e3248d2 X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=711e4ccf-2e9b-4bcf-a551-4094005b6194; Ip=[50.232.66.26]; Helo=[CAEXCH02.caveonetworks.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN4PR0701MB3823 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Quinn Tran As part of chip reset, all commands from all QPairs are flushed. This patch fixes code to use Q Pair lock for flush instead of using old hardware_lock. Signed-off-by: Quinn Tran Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/qla_os.c | 158 ++++++++++++++++++++++-------------------- 1 file changed, 84 insertions(+), 74 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index 029b95b2bd8a..2e4bfb7aabf7 100644 --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c @@ -1704,93 +1704,103 @@ qla2x00_loop_reset(scsi_qla_host_t *vha) return QLA_SUCCESS; } -void -qla2x00_abort_all_cmds(scsi_qla_host_t *vha, int res) +static void +__qla2x00_abort_all_cmds(struct qla_qpair *qp, int res) { - int que, cnt, status; + int cnt, status; unsigned long flags; srb_t *sp; + scsi_qla_host_t *vha = qp->vha; struct qla_hw_data *ha = vha->hw; struct req_que *req; struct qla_tgt *tgt = vha->vha_tgt.qla_tgt; struct qla_tgt_cmd *cmd; uint8_t trace = 0; - spin_lock_irqsave(&ha->hardware_lock, flags); - for (que = 0; que < ha->max_req_queues; que++) { - req = ha->req_q_map[que]; - if (!req) - continue; - if (!req->outstanding_cmds) - continue; - for (cnt = 1; cnt < req->num_outstanding_cmds; cnt++) { - sp = req->outstanding_cmds[cnt]; - if (sp) { - req->outstanding_cmds[cnt] = NULL; - if (sp->cmd_type == TYPE_SRB) { - if (sp->type == SRB_NVME_CMD || - sp->type == SRB_NVME_LS) { - sp_get(sp); - spin_unlock_irqrestore( - &ha->hardware_lock, flags); - qla_nvme_abort(ha, sp); - spin_lock_irqsave( - &ha->hardware_lock, flags); - } else if (GET_CMD_SP(sp) && - !ha->flags.eeh_busy && - (!test_bit(ABORT_ISP_ACTIVE, - &vha->dpc_flags)) && - (sp->type == SRB_SCSI_CMD)) { - /* - * Don't abort commands in - * adapter during EEH - * recovery as it's not - * accessible/responding. - * - * Get a reference to the sp - * and drop the lock. The - * reference ensures this - * sp->done() call and not the - * call in qla2xxx_eh_abort() - * ends the SCSI command (with - * result 'res'). - */ - sp_get(sp); - spin_unlock_irqrestore( - &ha->hardware_lock, flags); - status = qla2xxx_eh_abort( - GET_CMD_SP(sp)); - spin_lock_irqsave( - &ha->hardware_lock, flags); - /* - * Get rid of extra reference - * if immediate exit from - * ql2xxx_eh_abort - */ - if (status == FAILED && - (qla2x00_isp_reg_stat(ha))) - atomic_dec( - &sp->ref_count); - } - sp->done(sp, res); - } else { - if (!vha->hw->tgt.tgt_ops || !tgt || - qla_ini_mode_enabled(vha)) { - if (!trace) - ql_dbg(ql_dbg_tgt_mgt, - vha, 0xf003, - "HOST-ABORT-HNDLR: dpc_flags=%lx. Target mode disabled\n", - vha->dpc_flags); - continue; - } - cmd = (struct qla_tgt_cmd *)sp; - qlt_abort_cmd_on_host_reset(cmd->vha, - cmd); + spin_lock_irqsave(qp->qp_lock_ptr, flags); + req = qp->req; + for (cnt = 1; cnt < req->num_outstanding_cmds; cnt++) { + sp = req->outstanding_cmds[cnt]; + if (sp) { + req->outstanding_cmds[cnt] = NULL; + if (sp->cmd_type == TYPE_SRB) { + if (sp->type == SRB_NVME_CMD || + sp->type == SRB_NVME_LS) { + sp_get(sp); + spin_unlock_irqrestore(qp->qp_lock_ptr, + flags); + qla_nvme_abort(ha, sp); + spin_lock_irqsave(qp->qp_lock_ptr, + flags); + } else if (GET_CMD_SP(sp) && + !ha->flags.eeh_busy && + (!test_bit(ABORT_ISP_ACTIVE, + &vha->dpc_flags)) && + (sp->type == SRB_SCSI_CMD)) { + /* + * Don't abort commands in + * adapter during EEH + * recovery as it's not + * accessible/responding. + * + * Get a reference to the sp + * and drop the lock. The + * reference ensures this + * sp->done() call and not the + * call in qla2xxx_eh_abort() + * ends the SCSI command (with + * result 'res'). + */ + sp_get(sp); + spin_unlock_irqrestore(qp->qp_lock_ptr, + flags); + status = qla2xxx_eh_abort( + GET_CMD_SP(sp)); + spin_lock_irqsave(qp->qp_lock_ptr, + flags); + /* + * Get rid of extra reference + * if immediate exit from + * ql2xxx_eh_abort + */ + if (status == FAILED && + (qla2x00_isp_reg_stat(ha))) + atomic_dec( + &sp->ref_count); + } + sp->done(sp, res); + } else { + if (!vha->hw->tgt.tgt_ops || !tgt || + qla_ini_mode_enabled(vha)) { + if (!trace) + ql_dbg(ql_dbg_tgt_mgt, + vha, 0xf003, + "HOST-ABORT-HNDLR: dpc_flags=%lx. Target mode disabled\n", + vha->dpc_flags); + continue; } + cmd = (struct qla_tgt_cmd *)sp; + qlt_abort_cmd_on_host_reset(cmd->vha, cmd); } } } - spin_unlock_irqrestore(&ha->hardware_lock, flags); + spin_unlock_irqrestore(qp->qp_lock_ptr, flags); +} + +void +qla2x00_abort_all_cmds(scsi_qla_host_t *vha, int res) +{ + int que; + struct qla_hw_data *ha = vha->hw; + + __qla2x00_abort_all_cmds(ha->base_qpair, res); + + for (que = 0; que < ha->max_qpairs; que++) { + if (!ha->queue_pair_map[que]) + continue; + + __qla2x00_abort_all_cmds(ha->queue_pair_map[que], res); + } } static int