From patchwork Wed Jul 18 21:26:45 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Madhani, Himanshu" X-Patchwork-Id: 10533293 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 2E37F600F4 for ; Wed, 18 Jul 2018 21:27:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1DE1E29823 for ; Wed, 18 Jul 2018 21:27:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1162229837; Wed, 18 Jul 2018 21:27:05 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, MAILING_LIST_MULTI, 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 7BF8229823 for ; Wed, 18 Jul 2018 21:27:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730211AbeGRWGt (ORCPT ); Wed, 18 Jul 2018 18:06:49 -0400 Received: from mail-sn1nam02on0059.outbound.protection.outlook.com ([104.47.36.59]:27987 "EHLO NAM02-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726968AbeGRWGt (ORCPT ); Wed, 18 Jul 2018 18:06:49 -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:X-MS-Exchange-SenderADCheck; bh=ZypwnS/KIZRjJhDD4wMtKbx30p+lCstCBOuLlSjO+rw=; b=GL3QobDZl5uB519jaP7KdI54nD2iG1EfNY31THMNTDcalVvG1catDpEdtuQh87E2YBmp0ZHrC5qWyTRBe/mO9204V3f3kyAT+IZRiB0QHfy1uU45uO1rrFu0c1E3Rn2MhWpLeN/bauYiwzo5/VHy44R82VC9dMjLZXov3b9ZXXc= Received: from DM6PR07CA0001.namprd07.prod.outlook.com (2603:10b6:5:94::14) by BY1PR0701MB1384.namprd07.prod.outlook.com (2a01:111:e400:4810::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.973.16; Wed, 18 Jul 2018 21:27:00 +0000 Received: from DM3NAM05FT028.eop-nam05.prod.protection.outlook.com (2a01:111:f400:7e51::203) by DM6PR07CA0001.outlook.office365.com (2603:10b6:5:94::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.973.16 via Frontend Transport; Wed, 18 Jul 2018 21:26:59 +0000 Authentication-Results: spf=pass (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=bestguesspass action=none header.from=cavium.com; Received-SPF: Pass (protection.outlook.com: domain of cavium.com designates 50.232.66.26 as permitted sender) receiver=protection.outlook.com; client-ip=50.232.66.26; helo=CAEXCH02.caveonetworks.com; Received: from CAEXCH02.caveonetworks.com (50.232.66.26) by DM3NAM05FT028.mail.protection.outlook.com (10.152.98.139) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.20.995.0 via Frontend Transport; Wed, 18 Jul 2018 21:26:59 +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; Wed, 18 Jul 2018 14:26:55 -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 w6ILQtsl013372; Wed, 18 Jul 2018 14:26:55 -0700 Received: (from root@localhost) by dut1171.mv.qlogic.com (8.14.7/8.14.7/Submit) id w6ILQtjI013371; Wed, 18 Jul 2018 14:26:55 -0700 From: Himanshu Madhani To: , CC: , Subject: [PATCH 03/12] qla2xxx: Add longer window for Chip reset Date: Wed, 18 Jul 2018 14:26:45 -0700 Message-ID: <20180718212654.13325-4-himanshu.madhani@cavium.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20180718212654.13325-1-himanshu.madhani@cavium.com> References: <20180718212654.13325-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)(136003)(39860400002)(346002)(396003)(2980300002)(438002)(199004)(189003)(44832011)(5660300001)(478600001)(87636003)(446003)(305945005)(16586007)(106002)(76176011)(42186006)(110136005)(316002)(356003)(36756003)(336012)(14444005)(26005)(6666003)(476003)(486006)(126002)(1076002)(2616005)(69596002)(72206003)(11346002)(186003)(80596001)(51416003)(54906003)(48376002)(8936002)(8676002)(81166006)(81156014)(106466001)(47776003)(4326008)(2906002)(50226002)(50466002)(575784001)(86362001)(148743002); DIR:OUT; SFP:1101; SCL:1; SRVR:BY1PR0701MB1384; H:CAEXCH02.caveonetworks.com; FPR:; SPF:Pass; LANG:en; PTR:50-232-66-26-static.hfc.comcastbusiness.net; A:1; MX:1; X-Microsoft-Exchange-Diagnostics: 1; DM3NAM05FT028; 1:KWI8/d6OBNeqyXZRkChzwgMWDlEdF2zbataue1OcJWoEUKow1QIMR2yt7+y2lz87m5k8ZpPkLsOnknogEjhQP7PTo96BmuIyJ7owQ4uB2VemBvKJQGQiUwAcbkFPdYJs X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2f228d75-680e-4daa-9f80-08d5ecf53235 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989117)(5600053)(711020)(4608076)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060); SRVR:BY1PR0701MB1384; X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1384; 3:Yn81KY3XbPH9oHBYcgAcdhlUHoDwYNE6ZsW4kaoPO87nH/PG0N02fCgn5tOa0w8JGtbIqS3wv7ZxIgG1nhiZgS9/rzMd+RSw9oQsECQQBH4fnHq+zepswwcaTQDBfiaXmxmalN4GgnglnHg6oIy+bwCGLQJQHti3i8Vo+wisC4tkJemZW86QdIATVInqD4DbrDUrWLze+DdK2JL7+MSdSEJGmsP19nVHYe0eSW2SIPU5OTg175976kvzp0kG2gEDuMaYJC/DJChcHkvXKSkANGg6bj4SIV5N2iQ+NQbpoEnd8Y7K2sXRAARKuhxqWalj0Qcd8EZN6Xy1DU9D95tawmzCq4MfhCHycLs1Dt29f2E=; 25:2TpgL5Ee9u3c7UyNmOY0i4i7WE4YZDCARimBRLRs4+DdvHZdknCTHqqEjFXOckNJv6T0mlT8iK+3Ufv5EK0tqoEApxbpmTPwR8JkJeaRwuQunvbShRoOBHpD9EYG/CUW4ugvNu+IVC0oyLQubfc1eY/6PHmcRjFKi+8MVL/tIjVIWqE2Dgh/ctwTncNZ/s7UCkhZju5EGCpDC8ljWwNjH/H5TpAy2MoiLogXqEbZszu+/DTq2McXMPYp4lt1EPnw7O+prY1ZxJD3/ri2eKgPhQrx0W5UKjkIdFPzKNG0wc/HuuSYsU/gXPvc5NOh09YbBVJWoNXkXedGeUH5hp2WoA== X-MS-TrafficTypeDiagnostic: BY1PR0701MB1384: X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1384; 31:W9/J9R7QNakUFcwjzVEjmWhUCHDpDaNFxR3BgU57pp72wz2TUb9MpdQbYt6WaUm5lZ5TxsIFBabCcwW6lKxMpt3+Z4WPw7yIf9PQ/8XKXFygNVX84awkR2OAjtxQ71+eY0wLRPpy4q/Fu9NRD8y+MRUa78PiPmxr/zaMG1DkFsoXEDFOV18M3mVuCAmj0jThBeDcviBswpxTVBI7nDMc1cVjvb0yO9b7FHBJpuFVauI=; 20:Vt8kksy3wH+1PM9DX2rkf0H8+D5yVWh2jNY4RLdhApP/EY36OFgQ6fvcsVLy1Ep3d94fP3ah/qfA2UtQqNWHDXSoaB5VM5F8q1T3oRPVjyiKH9SbtkIZaSWlHyTuZAbIueedqcnDTvIuKAwPmpgFdZ6QNkZMNOyT5Cug95U7qDv+JU+3Goepa55+DZtMsr6EI8LnfDzch3lyrUC890xH646jARpvGo9Wx5lVcsi9XyFQOz+OBJrctOfhXMLVbKOM8APfCrjN/GhaZ4TVNdpkmEDfBej9rpNUMflUOfHO07OAm08gaUlwrkMP9CQ8Uzs/Y6/125f3Hyx0u8VwzTVHX2wFsFN6c7v4PsirQQ3doUANvD3maheOxQrRjv1/8gv8AyVK5pdhnKWBb2PgsF8BdTtHyyYFgd0fjJ0vmyOksiVDABalOHsalSBzKj39fEuPuhBF5xzDQH07BQcNmW8syybCpzByi69wytgpdk/9g63VNkGAw06Ci2S8wSvVYRmZ X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(93006095)(93004095)(3231311)(944501410)(52105095)(3002001)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123558120)(20161123562045)(20161123564045)(6072148)(201708071742011)(7699016); SRVR:BY1PR0701MB1384; BCL:0; PCL:0; RULEID:; SRVR:BY1PR0701MB1384; X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1384; 4:AlGUyjJ1FBh0V9TJ9DwMjo20zEpeHVpurZmQuvCP13z7Ar52KbqDD6U6HtKToONsopfykL668FqOKWstLv8hMLyuL/Mwbi35BdFnlah8ic3daakeTlSgk7uONF6TkleecQp+HvGknID61wNWqRawqYhH9LuFyYizY/NPJ8a/dFYqinHBihOUb84KnpPbA+EMmhiiMEeXGYr8TS2VciZJacae6pbSyz4MDGeYkxNS39yuLD5gDG/1doBta1A32PtIPM/VRLF1+v6tadut9rqI7A== X-Forefront-PRVS: 0737B96801 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BY1PR0701MB1384; 23:xtA65I3F1ZBDDxxTwtBDvjF3XiQjPxMuFiwzHKQ?= =?us-ascii?Q?dMHZ8EqMiLMyPGhAy3oCTuJYqadq6RsXXoigUeBq/RZMA04ctj7W6ghjficJ?= =?us-ascii?Q?p2QDG8cFomCxlH+D5nwjLWCNr0jPm9GZqkdWt7lFH20GjZqv9DVxevQH6oCB?= =?us-ascii?Q?1I36m9G0E4HNJvdm64mZqjHAAW0SQDQMVRYeM4a+IKWCzPuaf/xOnowrf5CB?= =?us-ascii?Q?cjAZWY0IV4xBDsSh6IxRa9c2MRvDsF3HzOMr3Sj2kQgyg6NQkD31bquwLlDw?= =?us-ascii?Q?40WTGAD05YVp9mHmkTXLMgdN+peS9+gwsufyqs6Eo+PovcTEiZsVNSfBAWFM?= =?us-ascii?Q?1S/KD5AhiFDdYoJNKI4fq5ByPa6doGyMh4xOXm3tATGtv93u+a0vLmhx5uLH?= =?us-ascii?Q?rT3W8OLp0kj+A4aNQ+GSwWRbgyr6ivtPRh+3MnyYvUrIPyQi9qC7d91/Rg8y?= =?us-ascii?Q?8YQQRhmaeN6xKMtZXicRPjTwSBtcwZECCbSAZt+oB0HITlVMnk9sR+I+jWc7?= =?us-ascii?Q?kNDeHOvhz2K7jRAIVyq8Cf6ccAkaSnAyDVBJYu8ATk+21SLuxuoxa0Tm2Go1?= =?us-ascii?Q?jhr5Xg26xRcc2yXNHBrmsdWkj8iauQ/iC/jJp3hqf7ItwkyXjfjo6YQ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VPGYNj+FRc8= X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1384; 6:6m9LfIoxjPQTmbHBpXK/Px/aQchy/rWra0BjP5jAp9K+osVz93nO3V9PyYAYku52XUibY3MM9qY2avhHIompcGL5j7LMqBrfsP8fyfRXBrVdRKD6YJalL5OR7qPbw7oBkEzE/hJWHlwYqwI7QXL9pX9sUSpHAZpJSqJ56jlFwjW43dPYvaIQAgqdoStxiBAw3hVkcNFR/gaPcCjOwUtHAQkF4WF3EfwfDUHP/NlvxxUHKeuFvrjX0n1f3X4Rv9oXNTq4v7Y1p/cgye1qQOBIMreyJdZpP/G0q75TXrj8P7ytXqU3pXWxuBrvja9G/itDwgKtpB89TwM+ldQUcZ7U6FZe/+g9Zl6NILsGHz/OjJDmoHSpyrTqrinskarcvxGsu6ZuPdK62sV1v2GE+gY/E/LMGptoMrGJUTs6OysJoYPcEgKlMC7SPdrCp+blknD7PMql7Hh4VXJH4HPZGDosrQ==; 5:rcs2brw3eRm5De2vLhuRWOEMS5VDRAyXGeMPN3VCEeQpdrvsg9r1OI6sry/W82s3y+mD4ssO1MZPH0PCaSoFYsfK1UP6tntpRyOsffnLJKa0GWdzzQOnmfV8YEiiLcRqkZCVXJUGc4d7qCaqBmZ4JBRVjiHPBxBh7K3+qT8cZeY=; 7:lToLguW/GfuBWt+Nxwck9JVkGW5tWiktEdVETUfJlKjAVbAAbWzpCakfN1T7QIdqPbNxGqa0V7h4sKtfUU6Xyjw8gUT5YSc5D8XDwG76y+wFNvO7ZJq0ZS/CyYkgbsdS0/yZnyAnkZvvSyNG+pbH7Q3WOhsIknLIYWMJr4kuihEGmV0yGnq74t/m9alZT5TfVl+hDNoC4GcupfsboYm6x1Etf3irwCYcJig8jG2Q1EmMZASrG9Y6sH5/sWuvieZT SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Jul 2018 21:26:59.3342 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2f228d75-680e-4daa-9f80-08d5ecf53235 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: BY1PR0701MB1384 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 The qla2x00_reset_active only cover the window of turning the chip off, add check to cover Chip on. Signed-off-by: Quinn Tran Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/qla_dbg.c | 3 +++ drivers/scsi/qla2xxx/qla_tmpl.c | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/scsi/qla2xxx/qla_dbg.c b/drivers/scsi/qla2xxx/qla_dbg.c index 5fd44c50bbac..c7533fa7f46e 100644 --- a/drivers/scsi/qla2xxx/qla_dbg.c +++ b/drivers/scsi/qla2xxx/qla_dbg.c @@ -1130,6 +1130,7 @@ qla24xx_fw_dump(scsi_qla_host_t *vha, int hardware_locked) ha->fw_dump); goto qla24xx_fw_dump_failed; } + QLA_FW_STOPPED(ha); fw = &ha->fw_dump->isp.isp24; qla2xxx_prep_dump(ha, ha->fw_dump); @@ -1384,6 +1385,7 @@ qla25xx_fw_dump(scsi_qla_host_t *vha, int hardware_locked) ha->fw_dump); goto qla25xx_fw_dump_failed; } + QLA_FW_STOPPED(ha); fw = &ha->fw_dump->isp.isp25; qla2xxx_prep_dump(ha, ha->fw_dump); ha->fw_dump->version = htonl(2); @@ -2036,6 +2038,7 @@ qla83xx_fw_dump(scsi_qla_host_t *vha, int hardware_locked) "request...\n", ha->fw_dump); goto qla83xx_fw_dump_failed; } + QLA_FW_STOPPED(ha); fw = &ha->fw_dump->isp.isp83; qla2xxx_prep_dump(ha, ha->fw_dump); diff --git a/drivers/scsi/qla2xxx/qla_tmpl.c b/drivers/scsi/qla2xxx/qla_tmpl.c index 731ca0d8520a..b170eb54aab5 100644 --- a/drivers/scsi/qla2xxx/qla_tmpl.c +++ b/drivers/scsi/qla2xxx/qla_tmpl.c @@ -1028,8 +1028,10 @@ qla27xx_fwdump(scsi_qla_host_t *vha, int hardware_locked) ql_log(ql_log_warn, vha, 0xd300, "Firmware has been previously dumped (%p)," " -- ignoring request\n", vha->hw->fw_dump); - else + else { + QLA_FW_STOPPED(vha->hw); qla27xx_execute_fwdt_template(vha); + } #ifndef __CHECKER__ if (!hardware_locked)