From patchwork Wed Jun 14 03:47:28 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Madhani, Himanshu" X-Patchwork-Id: 9785263 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 1F2596038E for ; Wed, 14 Jun 2017 03:48:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3193A28589 for ; Wed, 14 Jun 2017 03:48:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2640828294; Wed, 14 Jun 2017 03:48:39 +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=unavailable 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 7EBE328589 for ; Wed, 14 Jun 2017 03:48:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754243AbdFNDsh (ORCPT ); Tue, 13 Jun 2017 23:48:37 -0400 Received: from mail-dm3nam03on0040.outbound.protection.outlook.com ([104.47.41.40]:1472 "EHLO NAM03-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754205AbdFNDsR (ORCPT ); Tue, 13 Jun 2017 23:48:17 -0400 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=YDIpwWtxHeqzhi7/kD9GBt63wwbHSH2OBfiUQj0Mg2E=; b=afZH2wPYLrMZmBoQX3ZgcIhMosUcClFf9/gz58uO9hEbz5u70F1YVBg7wTKWlvi2RgFBRAUqtPcs78+NJwM7e6vK/U0zGj6veYwmAQl9dc/HbNgOFwvWXaQtwuOeqelBA0KBFEQpERsmJnXRcsQFGqluev+V1r18k0Xfk/DTFqM= Received: from DM5PR07CA0043.namprd07.prod.outlook.com (2603:10b6:3:16::29) by DM2PR07MB430.namprd07.prod.outlook.com (2a01:111:e400:243a::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1157.12; Wed, 14 Jun 2017 03:48:15 +0000 Received: from BY2FFO11FD018.protection.gbl (2a01:111:f400:7c0c::130) by DM5PR07CA0043.outlook.office365.com (2603:10b6:3:16::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1157.12 via Frontend Transport; Wed, 14 Jun 2017 03:48:15 +0000 Authentication-Results: spf=none (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: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) Received: from CAEXCH02.caveonetworks.com (50.232.66.26) by BY2FFO11FD018.mail.protection.outlook.com (10.1.14.106) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.1.1143.11 via Frontend Transport; Wed, 14 Jun 2017 03:48:14 +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; Tue, 13 Jun 2017 20:47:57 -0700 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 v5E3lvWX015515; Tue, 13 Jun 2017 20:47:57 -0700 Received: (from root@localhost) by dut1171.mv.qlogic.com (8.14.7/8.14.7/Submit) id v5E3lvnS015514; Tue, 13 Jun 2017 20:47:57 -0700 From: Himanshu Madhani To: , CC: , , Subject: [PATCH v2 13/15] qla2xxx: Move target stat counters from vha to qpair. Date: Tue, 13 Jun 2017 20:47:28 -0700 Message-ID: <20170614034730.15428-14-himanshu.madhani@cavium.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170614034730.15428-1-himanshu.madhani@cavium.com> References: <20170614034730.15428-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)(6009001)(39410400002)(39450400003)(39850400002)(39400400002)(39840400002)(2980300002)(428002)(199003)(189002)(9170700003)(2906002)(105586002)(101416001)(189998001)(86362001)(50466002)(48376002)(80596001)(305945005)(6666003)(1076002)(356003)(2950100002)(5660300001)(33646002)(76176999)(38730400002)(50986999)(54906002)(4326008)(47776003)(106466001)(87636003)(81166006)(5003940100001)(8936002)(42186005)(50226002)(36756003)(72206003)(8676002)(478600001); DIR:OUT; SFP:1101; SCL:1; SRVR:DM2PR07MB430; H:CAEXCH02.caveonetworks.com; FPR:; SPF:None; MLV:sfv; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BY2FFO11FD018; 1:v2iaEN9b0CwRhdxwCeWmO3n5xWD0xrA/4mJxy2Pv5088OVu9HgEL3fRG0LeJHgU1ETxNb8ErbmJxeDS1kVHOGcIESUpmYBtxXZ7wxZf5bnPzuPjeMMq62gSsYMmTMZqCfNVmO2lR2xfp4WzRVlfogEHcJPYwZDFClStDxl/JdVT+RQeqyN9P7dLfO3fAdYF7P8stUkmj+sInn/hUpUNC9sPYBFzjvalRpEKHC64LJOZz1LzWY1+aYmK1tmBu46ectnLhFe9Q+vAi8nPz7JRm5IFBbowbxyQglb7qVEPraTmxQtgMjC41noeHJxLTjGzxYbJYkwXNHZOeDvnXV20s59bN0VsOxYoP5Po33Tnw1asaCVW8agVT13LSsfjAZ8LPWrb3S+WqQ+dSuroUUUxKZSWe4eETtbaB1TGomTjh0b9KCRNK3MuAlrL/kfg3UyAHimhnrKgoYOB0iqm7Wb6LFO48RHMF5QjTrHefkzSUEHt7vCKTfrmhY6yuibegkRTog5KKxywOOuNTAdmv7FslbQ== X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM2PR07MB430: X-MS-Office365-Filtering-Correlation-Id: fd18967d-b342-499d-d951-08d4b2d82f8b X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254075)(201703131423075)(201703031133081)(201702281549075); SRVR:DM2PR07MB430; X-Microsoft-Exchange-Diagnostics: 1; DM2PR07MB430; 3:TfYAXb5FvTKahPftArndOLDhgfIL2+nuIEx5+S4e+GWJND+hmjrjKCKBiLECUzxuPKcoK904lQKvxjUKc1UjwDK/T9psQ8L6nkjvfmo22Dm4VOKw9mczCOISEG58mpvZKfCBlIl4ouoToKKZ/LBekaO10FvWjB4JZKE2+uTNi8h3X9Qlf1xNo8Nkj2H7Vg6ceVOfsqu2mEORPeLXGg1NON8UYXt9+FuyGfbt7x8iLqmIWHmBC0DvvcKxEKL/8xjSbcskX3qH3Ya+6wCNtEEaaMTbcIvWsqqr85Ov8isIHdmsC/SqrRl7TQFVzoUevNVKRBE+gg/tcloxcP2q1wJFphYYMGzK4xMEQItLFFaoyoaIWp4eEI1Zq/cHoKSpKDii9gGpIO9ZNUB8JHI+iX7OR1p4Tiype1m75+1QJAHFkq0XOGz9owDkkUCe6QbHj8CIBxwBxfOcCUZ9u2578Nva8blLGDzCOapZZvqLDf+DvLnHbfVqQSDmWNh7uXnGbLaH X-Microsoft-Exchange-Diagnostics: 1; DM2PR07MB430; 25:oSfoh3uzEE7Z4dclFCokFxBcmaDXFsYPogBT8jJ+kCcvLj6iCTSBR8Kl+6Nu2tWMieBk6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cyXjorSo36jFKx3CYIcQ7cgAJr7H1fGClPmZBfrxmUyT5BLHNf6wD8TnRyXdkxoUPQ02KUfxu521QlDZBRyiOblxE8kNgdL85djJoCVO4nZ5FU6q/eh6NmNRmEMHZs2S9kTmT55IR5mJCLKzkUvwMbbchxXCf11iqLF6FhjrUB X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(13016025)(8121501046)(13018025)(3002001)(10201501046)(100000703101)(100105400095)(93006095)(93001095)(6041248)(20161123560025)(20161123562025)(20161123555025)(20161123558100)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DM2PR07MB430; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DM2PR07MB430; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM2PR07MB430; 4:Z2mn6GK/QBKPRZSgZdeTbg4L4K+lpZVIVrfodBHn1Cv?= =?us-ascii?Q?zGUnOo5vCRm7wu9G/0MDLGrtP3Zg7LqcZ1jI/90sO/OVx6EqX4ckCAd/ohbN?= =?us-ascii?Q?0cC8cT20SM5AjiP8p6j81Wi/8O1M7pczf/4LZMowj9gb7pmWmzEJEoSUx0b+?= =?us-ascii?Q?WJYF+8j1DTim8io2RVBgGc5+J/ftlkdBZWdP8SrDJlDCWN8dYvja8D9+cKYR?= =?us-ascii?Q?AbjtZe6LemU7aMJ46MblX6lAV2j/TvH7UTBg6WLkH+p34GqEXmJY3aUvsvkB?= =?us-ascii?Q?oAO8Uxwf92vXwye1U1vg1rDj17IBSEOdL7HqAVQdT0Qp/hH7VFCyTNqGEelI?= =?us-ascii?Q?QbRM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nXphzBo0TGIDWvibk6GuFGdj0qP8kM/+awQXr11pRFLFy+DebiE8l0MboHEASly/w7UZK2dIWrBeP9GHwpIcUxiIINvz/O3UncX6IcNYF2WFExb+Fg1TBD8ZxfL6R97YuE6SnQ8ZHRDKisEl4MUz7ZvtfxvluWiUf3b9yQWx/fhlgrklvmQzhdfn6Sn3WenCQPFlk+TFSk2c+xip19fSvGfLLomkJcr1sR+9jpxrtHQ+rvH7ZyseOdFkNho5I5361kfT943jR6lNeCJN8JfwXO7dCSMmlKC1IBPKD7bIu2z0abj/iB0j37XmvsC4I5PRxgQ62bp/ZkTzy1E0DoFxhij9bDSrpINy76; 24:e+8VsWdkA1PWmTiJ3PvgiRqQw+1HH09zPO1bqZ9YkbSbNDq09yZYYTM+cE14F7bLDPEDF3YUHKqmHLpRNlAn8KsR2EnNpNOjQEdc6M/y1Pg= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DM2PR07MB430; 7:xcel6CKPYgb4/PVGVsBt+tcr6yNl+wEECB0JlH1c9grZIA86+7WcOeHJZxaKsmOv6Z1UBEWbZMiXHYz7/paxyU7bBHTXLTgSJNVZGHwhRphzuG9arepVcOAIT9XmD3C0QoEyHLTcMhkLiEVmZ7JExDQsOyaJeXBiRIeHIwFJaEBdK+IAW9I0fF9fNDz0GLWegiE1Jvigy431Kgt4xssadRyM8oxPNb3biJf499+YJZmwt0a6NrBjpuk+hKTQAySom7jOr9miVajtmaq6WpegXJ+rJ6+Sc0pL6JN4xDbyMxKQC9/Sfo+OP0G/odMxfk6DvwFhnCdcZdwjCqaQhebQCQ== X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Jun 2017 03:48:14.4428 (UTC) 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: DM2PR07MB430 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 Move counters to qpair to reduce cache miss. Signed-off-by: Quinn Tran Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/qla_def.h | 27 +++++++++++---------- drivers/scsi/qla2xxx/qla_dfs.c | 48 +++++++++++++++++++++++++++++++------- drivers/scsi/qla2xxx/qla_iocb.c | 2 +- drivers/scsi/qla2xxx/qla_target.c | 13 +++++------ drivers/scsi/qla2xxx/tcm_qla2xxx.c | 8 +++---- 5 files changed, 63 insertions(+), 35 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h index 17b13dd92511..e1af9db3691d 100644 --- a/drivers/scsi/qla2xxx/qla_def.h +++ b/drivers/scsi/qla2xxx/qla_def.h @@ -3183,6 +3183,18 @@ struct qla_tc_param { #define QLA_MAX_VPORTS_QLA24XX 128 #define QLA_MAX_VPORTS_QLA25XX 256 +struct qla_tgt_counters { + uint64_t qla_core_sbt_cmd; + uint64_t core_qla_que_buf; + uint64_t qla_core_ret_ctio; + uint64_t core_qla_snd_status; + uint64_t qla_core_ret_sta_ctio; + uint64_t core_qla_free_cmd; + uint64_t num_q_full_sent; + uint64_t num_alloc_iocb_failed; + uint64_t num_term_xchg_sent; +}; + struct qla_qpair; /* Response queue data structure */ @@ -3285,6 +3297,7 @@ struct qla_qpair { struct list_head qp_list_elem; /* vha->qp_list */ struct list_head hints_list; uint16_t cpuid; + struct qla_tgt_counters tgt_counters; }; /* Place holder for FW buffer parameters */ @@ -3964,18 +3977,6 @@ struct qla_hw_data { int allow_cna_fw_dump; }; -struct qla_tgt_counters { - uint64_t qla_core_sbt_cmd; - uint64_t core_qla_que_buf; - uint64_t qla_core_ret_ctio; - uint64_t core_qla_snd_status; - uint64_t qla_core_ret_sta_ctio; - uint64_t core_qla_free_cmd; - uint64_t num_q_full_sent; - uint64_t num_alloc_iocb_failed; - uint64_t num_term_xchg_sent; -}; - /* * Qlogic scsi host structure */ @@ -4140,10 +4141,8 @@ typedef struct scsi_qla_host { struct fc_host_statistics fc_host_stat; struct qla_statistics qla_stats; struct bidi_statistics bidi_stats; - atomic_t vref_count; struct qla8044_reset_template reset_tmplt; - struct qla_tgt_counters tgt_counters; uint16_t bbcr; struct name_list_extended gnl; /* Count of active session/fcport */ diff --git a/drivers/scsi/qla2xxx/qla_dfs.c b/drivers/scsi/qla2xxx/qla_dfs.c index 63d7374dce77..d231e7156134 100644 --- a/drivers/scsi/qla2xxx/qla_dfs.c +++ b/drivers/scsi/qla2xxx/qla_dfs.c @@ -164,26 +164,56 @@ static int qla_dfs_tgt_counters_show(struct seq_file *s, void *unused) { struct scsi_qla_host *vha = s->private; + struct qla_qpair *qpair = vha->hw->base_qpair; + uint64_t qla_core_sbt_cmd, core_qla_que_buf, qla_core_ret_ctio, + core_qla_snd_status, qla_core_ret_sta_ctio, core_qla_free_cmd, + num_q_full_sent, num_alloc_iocb_failed, num_term_xchg_sent; + u16 i; + + qla_core_sbt_cmd = qpair->tgt_counters.qla_core_sbt_cmd; + core_qla_que_buf = qpair->tgt_counters.core_qla_que_buf; + qla_core_ret_ctio = qpair->tgt_counters.qla_core_ret_ctio; + core_qla_snd_status = qpair->tgt_counters.core_qla_snd_status; + qla_core_ret_sta_ctio = qpair->tgt_counters.qla_core_ret_sta_ctio; + core_qla_free_cmd = qpair->tgt_counters.core_qla_free_cmd; + num_q_full_sent = qpair->tgt_counters.num_q_full_sent; + num_alloc_iocb_failed = qpair->tgt_counters.num_alloc_iocb_failed; + num_term_xchg_sent = qpair->tgt_counters.num_term_xchg_sent; + + for (i = 0; i < vha->hw->max_qpairs; i++) { + qpair = vha->hw->queue_pair_map[i]; + qla_core_sbt_cmd += qpair->tgt_counters.qla_core_sbt_cmd; + core_qla_que_buf += qpair->tgt_counters.core_qla_que_buf; + qla_core_ret_ctio += qpair->tgt_counters.qla_core_ret_ctio; + core_qla_snd_status += qpair->tgt_counters.core_qla_snd_status; + qla_core_ret_sta_ctio += + qpair->tgt_counters.qla_core_ret_sta_ctio; + core_qla_free_cmd += qpair->tgt_counters.core_qla_free_cmd; + num_q_full_sent += qpair->tgt_counters.num_q_full_sent; + num_alloc_iocb_failed += + qpair->tgt_counters.num_alloc_iocb_failed; + num_term_xchg_sent += qpair->tgt_counters.num_term_xchg_sent; + } seq_puts(s, "Target Counters\n"); seq_printf(s, "qla_core_sbt_cmd = %lld\n", - vha->tgt_counters.qla_core_sbt_cmd); + qla_core_sbt_cmd); seq_printf(s, "qla_core_ret_sta_ctio = %lld\n", - vha->tgt_counters.qla_core_ret_sta_ctio); + qla_core_ret_sta_ctio); seq_printf(s, "qla_core_ret_ctio = %lld\n", - vha->tgt_counters.qla_core_ret_ctio); + qla_core_ret_ctio); seq_printf(s, "core_qla_que_buf = %lld\n", - vha->tgt_counters.core_qla_que_buf); + core_qla_que_buf); seq_printf(s, "core_qla_snd_status = %lld\n", - vha->tgt_counters.core_qla_snd_status); + core_qla_snd_status); seq_printf(s, "core_qla_free_cmd = %lld\n", - vha->tgt_counters.core_qla_free_cmd); + core_qla_free_cmd); seq_printf(s, "num alloc iocb failed = %lld\n", - vha->tgt_counters.num_alloc_iocb_failed); + num_alloc_iocb_failed); seq_printf(s, "num term exchange sent = %lld\n", - vha->tgt_counters.num_term_xchg_sent); + num_term_xchg_sent); seq_printf(s, "num Q full sent = %lld\n", - vha->tgt_counters.num_q_full_sent); + num_q_full_sent); /* DIF stats */ seq_printf(s, "DIF Inp Bytes = %lld\n", diff --git a/drivers/scsi/qla2xxx/qla_iocb.c b/drivers/scsi/qla2xxx/qla_iocb.c index 6c710313adce..ac49febbac76 100644 --- a/drivers/scsi/qla2xxx/qla_iocb.c +++ b/drivers/scsi/qla2xxx/qla_iocb.c @@ -2189,7 +2189,7 @@ __qla2x00_alloc_iocbs(struct qla_qpair *qpair, srb_t *sp) } queuing_error: - vha->tgt_counters.num_alloc_iocb_failed++; + qpair->tgt_counters.num_alloc_iocb_failed++; return pkt; } diff --git a/drivers/scsi/qla2xxx/qla_target.c b/drivers/scsi/qla2xxx/qla_target.c index 48d82c67e223..8f75d27daae2 100644 --- a/drivers/scsi/qla2xxx/qla_target.c +++ b/drivers/scsi/qla2xxx/qla_target.c @@ -3078,9 +3078,9 @@ int qlt_xmit_response(struct qla_tgt_cmd *cmd, int xmit_type, spin_lock_irqsave(qpair->qp_lock_ptr, flags); if (xmit_type == QLA_TGT_XMIT_STATUS) - vha->tgt_counters.core_qla_snd_status++; + qpair->tgt_counters.core_qla_snd_status++; else - vha->tgt_counters.core_qla_que_buf++; + qpair->tgt_counters.core_qla_que_buf++; if (!qpair->fw_started || cmd->reset_count != qpair->chip_reset) { /* @@ -3500,7 +3500,7 @@ static int __qlt_send_term_exchange(struct qla_qpair *qpair, ret = 1; } - vha->tgt_counters.num_term_xchg_sent++; + qpair->tgt_counters.num_term_xchg_sent++; pkt->entry_count = 1; pkt->handle = QLA_TGT_SKIP_HANDLE | CTIO_COMPLETION_HANDLE_MARK; @@ -5103,7 +5103,7 @@ static int __qlt_send_busy(struct qla_qpair *qpair, return -ENOMEM; } - vha->tgt_counters.num_q_full_sent++; + qpair->tgt_counters.num_q_full_sent++; pkt->entry_count = 1; pkt->handle = QLA_TGT_SKIP_HANDLE | CTIO_COMPLETION_HANDLE_MARK; @@ -5466,13 +5466,12 @@ static void qlt_24xx_atio_pkt(struct scsi_qla_host *vha, static void qlt_response_pkt(struct scsi_qla_host *vha, struct rsp_que *rsp, response_t *pkt) { - struct qla_hw_data *ha = vha->hw; struct qla_tgt *tgt = vha->vha_tgt.qla_tgt; if (unlikely(tgt == NULL)) { ql_dbg(ql_dbg_tgt, vha, 0xe05d, - "qla_target(%d): Response pkt %x received, but no " - "tgt (ha %p)\n", vha->vp_idx, pkt->entry_type, ha); + "qla_target(%d): Response pkt %x received, but no tgt (ha %p)\n", + vha->vp_idx, pkt->entry_type, vha->hw); return; } diff --git a/drivers/scsi/qla2xxx/tcm_qla2xxx.c b/drivers/scsi/qla2xxx/tcm_qla2xxx.c index 238abad4b481..5357c2031a1c 100644 --- a/drivers/scsi/qla2xxx/tcm_qla2xxx.c +++ b/drivers/scsi/qla2xxx/tcm_qla2xxx.c @@ -284,7 +284,7 @@ static void tcm_qla2xxx_complete_free(struct work_struct *work) WARN_ON(cmd->trc_flags & TRC_CMD_FREE); - cmd->vha->tgt_counters.qla_core_ret_sta_ctio++; + cmd->qpair->tgt_counters.qla_core_ret_sta_ctio++; cmd->trc_flags |= TRC_CMD_FREE; transport_generic_free_cmd(&cmd->se_cmd, 0); } @@ -296,7 +296,7 @@ static void tcm_qla2xxx_complete_free(struct work_struct *work) */ static void tcm_qla2xxx_free_cmd(struct qla_tgt_cmd *cmd) { - cmd->vha->tgt_counters.core_qla_free_cmd++; + cmd->qpair->tgt_counters.core_qla_free_cmd++; cmd->cmd_in_wq = 1; WARN_ON(cmd->trc_flags & TRC_CMD_DONE); @@ -492,7 +492,7 @@ static int tcm_qla2xxx_handle_cmd(scsi_qla_host_t *vha, struct qla_tgt_cmd *cmd, } #endif - cmd->vha->tgt_counters.qla_core_sbt_cmd++; + cmd->qpair->tgt_counters.qla_core_sbt_cmd++; return target_submit_cmd(se_cmd, se_sess, cdb, &cmd->sense_buffer[0], cmd->unpacked_lun, data_length, fcp_task_attr, data_dir, flags); @@ -520,7 +520,7 @@ static void tcm_qla2xxx_handle_data_work(struct work_struct *work) } spin_unlock_irqrestore(&cmd->cmd_lock, flags); - cmd->vha->tgt_counters.qla_core_ret_ctio++; + cmd->qpair->tgt_counters.qla_core_ret_ctio++; if (!cmd->write_data_transferred) { /* * Check if se_cmd has already been aborted via LUN_RESET, and