Message ID | 20180425130905.6385-12-chad.dupuis@cavium.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show
Return-Path: <linux-scsi-owner@kernel.org> 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 C2A60601D3 for <patchwork-linux-scsi@patchwork.kernel.org>; Wed, 25 Apr 2018 13:09:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B296528DF6 for <patchwork-linux-scsi@patchwork.kernel.org>; Wed, 25 Apr 2018 13:09:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A796428E00; Wed, 25 Apr 2018 13:09:36 +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 24A4E28DF6 for <patchwork-linux-scsi@patchwork.kernel.org>; Wed, 25 Apr 2018 13:09:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753937AbeDYNJf (ORCPT <rfc822;patchwork-linux-scsi@patchwork.kernel.org>); Wed, 25 Apr 2018 09:09:35 -0400 Received: from mail-sn1nam01on0044.outbound.protection.outlook.com ([104.47.32.44]:43760 "EHLO NAM01-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752885AbeDYNJ0 (ORCPT <rfc822;linux-scsi@vger.kernel.org>); Wed, 25 Apr 2018 09:09:26 -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=OAHFE077nUuX3SJTn5OdzOqXTBX8izKoNpVGmthLZEE=; b=DXbHDRG0HRIGn5YdyttMOfzgG6kBGug0NMfT74GOyV8RMP7QdPT5F8iWFwjbspnbrYaApWptFsGpi8v+n+52og4RXyaWfLYCR5MOzkdPK0WhNOSLh+BqTYSpbkV6X0zc2T46R332pxKcinjsMvczDf3O3IWi+MoIsMSCpDdI0fs= Received: from SN4PR0701CA0022.namprd07.prod.outlook.com (2603:10b6:803:28::32) by BY2PR07MB1507.namprd07.prod.outlook.com (2a01:111:e400:5850::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.696.13; Wed, 25 Apr 2018 13:09:25 +0000 Received: from BN1AFFO11FD006.protection.gbl (2a01:111:f400:7c10::199) by SN4PR0701CA0022.outlook.office365.com (2603:10b6:803:28::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.715.18 via Frontend Transport; Wed, 25 Apr 2018 13:09:24 +0000 Authentication-Results: spf=pass (sender IP is 50.232.66.26) smtp.mailfrom=cavium.com; oracle.com; dkim=none (message not signed) header.d=none;oracle.com; 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 BN1AFFO11FD006.mail.protection.outlook.com (10.58.52.66) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.20.653.14 via Frontend Transport; Wed, 25 Apr 2018 13:09:24 +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, 25 Apr 2018 06:09:22 -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 w3PD982n006464; Wed, 25 Apr 2018 06:09:08 -0700 Received: (from root@localhost) by dut1171.mv.qlogic.com (8.14.7/8.14.7/Submit) id w3PD98Re006463; Wed, 25 Apr 2018 06:09:08 -0700 From: Chad Dupuis <chad.dupuis@cavium.com> To: <martin.petersen@oracle.com> CC: <linux-scsi@vger.kernel.org>, <james.bottomley@hansenpartnership.com>, <QLogic-Storage-Upstream@cavium.com> Subject: [PATCH 11/21] qedf: Check if link is alraedy up when receiving a link up event from qed. Date: Wed, 25 Apr 2018 06:08:55 -0700 Message-ID: <20180425130905.6385-12-chad.dupuis@cavium.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20180425130905.6385-1-chad.dupuis@cavium.com> References: <20180425130905.6385-1-chad.dupuis@cavium.com> MIME-Version: 1.0 Content-Type: text/plain X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:50.232.66.26; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(39860400002)(346002)(376002)(396003)(39380400002)(2980300002)(438002)(199004)(189003)(446003)(48376002)(336012)(80596001)(106466001)(186003)(26005)(126002)(2906002)(51416003)(316002)(476003)(76176011)(486006)(69596002)(36756003)(2616005)(11346002)(50466002)(59450400001)(86362001)(478600001)(42186006)(47776003)(54906003)(6916009)(16586007)(2351001)(72206003)(8936002)(106002)(6666003)(50226002)(87636003)(356003)(5660300001)(107886003)(8676002)(81166006)(305945005)(44832011)(4326008)(1076002)(81156014); DIR:OUT; SFP:1101; SCL:1; SRVR:BY2PR07MB1507; 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; BN1AFFO11FD006; 1:CSaN4m32zQ0iWkveXw3rH2K4VJGMJWZLR3K4NJXlXYuKrdZhi3/dS/NvX6uP+5NOp3rlH1x8PTwVgAT+JTQFD7z20lUgP3wxNepalMUWQAHsUU5v4mBByEiLZJ5jATni X-MS-PublicTrafficType: Email X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4608076)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060); SRVR:BY2PR07MB1507; X-Microsoft-Exchange-Diagnostics: 1; BY2PR07MB1507; 3:ObbFBiPLQljDnETzwDSXhZuqZVNLK55Xyr/9fhDbdjlUihjj3q5npyq/w7MshGD6F11g4RSJv+9I6aomTkc4H2B0OAaXc95BGw7mh6bt7GOzr4GdBni9OHYjyyeVZopFP9tx5jPoxjUQwcau30u/ujwQwH8XGmula/uJxvToIKI9VlcpjKdDT1MLnvgiVcM4T/vv9kNrIk+NkB9niH2L1ixJoH3Cp/3L5loo/CaGfMdyNU/86m8D/nNDfSAv4d1k4/x+jGSnqEZGd00dtJleJZCMAw4eNaN706ZQkBtaCc+MBeA7U0Qp7bGvQOml01Lt4GmjaH9e3njowlKabSkLWG5tq0wrJTQnnsqsjVNFFAg=; 25:1m9g2KZNwvDGVOFCOLMTl0/9PuvQ91pJx2PNjHYTYiaDKIUrMjaE4kaS/JIihlEqROJO5eviUQxzP/DSZ4KXAmc7i5Xfxqd4JprZshqDOmRq9UkJFMsE9KR2bxo5JfKLmBsVGqeuu/xybyQApCb3++ZUOpgosjw2zMWH6S+TUeRuca9Qvtqw04Sx8Liqko9ZkiY+u64WrQ//izPDjOpG4sKEqyP4xLavlPg3kIaogQEMVNyp692Z7zTIFjTveqrT1d0Hx8W19ZJarR100HO17KwlknxYEsa44RLpTK3QWKQ9G70MVrxgeQYWR1ZGmHcLcpI2W+Gwyp/ua1iltuPTwA== X-MS-TrafficTypeDiagnostic: BY2PR07MB1507: X-Microsoft-Exchange-Diagnostics: 1; BY2PR07MB1507; 31:73hhcqmnL3OTpX9coaRaBCoO603S2wVvf+iY4+kEXTURuni1ZczuZWlpYKw6Ww19ZBiLod28RsnNps9becyuBx4mp0fm/LYn6Js6LiwUs3+ifGFK1YTsKM2EEWonoo9bFkEW1DL7MSGwlWe53SW06tv0jUMdG1LXA/0HpDXIjwE+GEmYY45PFItuZ+6XxqIcciU5lIYQEVBbJtttTylcCOd28aCbli3fSih4AmqpBoE=; 20:VI0E+JwacChzhs7qg/YjVtOHrGqGw+Z59Ze82lx6PPRs3HB3CtQPS8ViDnZ/H3zxLeYjt2hDI5qquj5T807oc3zchoGonjtnv2Ivn8rwgDUDGi7EU0xCw6jTJHKiH8JtjttKIsOcHotCOnsv9bWIudv4utEMIAExNxgJSIF4DP9OMMObk9FPNgmxGAcLcMV1WrUXRNH1/5waGjZHHT1Y2klYWnz2Xtj2o+8lCHQ9qDgsXe++PIVEoafdK70hx/A5/tZKfiAXJ/h/bia0xsge2EKEqPMHT2mTeD3VZEd/I39RldC0wUDI5F/k73PDsGDJcQoFxbgh+Ts94M+5980+YD7C6hmDicjw4OBjOG1bjEbgqKVn4Fch33hO6LOa1C3i6/ruuFtDxYIH7XyB6s1DqPj7yldf7YRAjlNZE6TpahSNadWG7nmU0p6B6nXsQ94YnqSqpoGkGkEnKQb+2dCbzWy8QELTZGGUkd7JgvoFhhLjQFLMBxj3lPNAP4v7svMm X-Microsoft-Antispam-PRVS: <BY2PR07MB1507B6BD3955A8DFC5E395AB9E8F0@BY2PR07MB1507.namprd07.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(93006095)(93004095)(3231232)(944501410)(52105095)(3002001)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(20161123558120)(20161123564045)(6072148)(201708071742011); SRVR:BY2PR07MB1507; BCL:0; PCL:0; RULEID:; SRVR:BY2PR07MB1507; X-Microsoft-Exchange-Diagnostics: 1; BY2PR07MB1507; 4:g4ETNDsqt6hE/YsgIn7MNPX19wX+2eHLGBC8i6MZ2u3tvrwzPEe8quujnkth+1YkLUJCjBiT3cvgT+Uv+bZpZnxYm4JyDCIv7LUrRxui2xYgFTn/8D0pIDbP0eKwTPWXBSYhmo2hIyzvnQqljvqwxuTiYWm7KQubPJCLW0opG9u084SH0lDltXv/p780NhFn4uDNbLsjAY3qo9Fl3Dix/UF0RNy+nliUu0092Vg3+QG6rH1B9a07tepSOj3kgooix2Ba1PIG9L2khT8XbMDhhg== X-Forefront-PRVS: 06530126A4 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BY2PR07MB1507; 23:YRrijjnoEIHuqPVew37PBZrARWGdebgxLPuGEVcZ8?= =?us-ascii?Q?RICIq4jwuMrtD362Uc6dQ0NxVZooMNqHgSr4r88lUziGMLCIq34IxdvM/Tz1?= =?us-ascii?Q?ieAyCm0RtTow5xrYWCAWSmBnZaEDKg8a5IOBufRVFgVm3cetE6sA4l9Mg5EH?= =?us-ascii?Q?iSQk7h4I+7iCYC8VWfonVNqSRrh7DvXLdNNZluedr6zlqLncX1JFOGiryu+t?= =?us-ascii?Q?NwdrkxET5bCZjbM2Gq3lKOC4I0NrsKeWN+4NCPV870UebkRT0Tc4SCPfNwZo?= =?us-ascii?Q?hfdAu/1c1dxjbrKlw1Z2qECbA0KWgeS/+zLk7wF7j4b+Z6YVjkg2nOHAcmV6?= =?us-ascii?Q?pGZt8Tcc9qH2JIh2UGbnGeq8QFZcJsCG9uZrJC/RzSWJ0jrEtp3sT7IeA8IE?= =?us-ascii?Q?BHEuh4dI+qkcSncdiQFLbyVvTcy3BdTLqaoxpn3pmacfMqR5IoUo9YcbOLQN?= =?us-ascii?Q?sHMEnxTPZWQsYzd/rTuMTKGHKVedOCZOYE6W+s+SDj8CDh+nOCb1CO3jAUA0?= =?us-ascii?Q?j3lsG0hB1HGS7Kn2fKsQ0Wi32z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yCTMwReze X-MS-Office365-Filtering-Correlation-Id: cb926788-3750-44b1-9238-08d5aaadc4bc X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Apr 2018 13:09:24.5961 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: cb926788-3750-44b1-9238-08d5aaadc4bc 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: BY2PR07MB1507 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: <linux-scsi.vger.kernel.org> X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/drivers/scsi/qedf/qedf_main.c b/drivers/scsi/qedf/qedf_main.c index 64491ae60059..866989ccd66e 100644 --- a/drivers/scsi/qedf/qedf_main.c +++ b/drivers/scsi/qedf/qedf_main.c @@ -485,6 +485,11 @@ static void qedf_link_update(void *dev, struct qed_link_output *link) struct qedf_ctx *qedf = (struct qedf_ctx *)dev; if (link->link_up) { + if (atomic_read(&qedf->link_state) == QEDF_LINK_UP) { + QEDF_INFO((&qedf->dbg_ctx), QEDF_LOG_DISC, + "Ignoring link up event as link is already up.\n"); + return; + } QEDF_ERR(&(qedf->dbg_ctx), "LINK UP (%d GB/s).\n", link->speed / 1000);
Signed-off-by: Chad Dupuis <chad.dupuis@cavium.com> --- drivers/scsi/qedf/qedf_main.c | 5 +++++ 1 file changed, 5 insertions(+)