From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9E2C4A04F0 for ; Thu, 19 Dec 2019 15:40:42 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 920801BFD5; Thu, 19 Dec 2019 15:40:42 +0100 (CET) Received: from mail-wr1-f67.google.com (mail-wr1-f67.google.com [209.85.221.67]) by dpdk.org (Postfix) with ESMTP id 4F6651BFF4 for ; Thu, 19 Dec 2019 15:40:41 +0100 (CET) Received: by mail-wr1-f67.google.com with SMTP id c14so6218979wrn.7 for ; Thu, 19 Dec 2019 06:40:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=d/qnTZeO6/zeeOj3JJ0Fesvkz/ASGCfcuV1CEBTmLnI=; b=OnC/w3Ca7AKQTCLy7eO1gL8A5NJnit9JA3oMvCVXaNn4Mlguf0pnHygqDSRwu9tadR 0naFhS47bldb1X9+NXUAyhWOKSkf03oTZ8XMtb4ZJvCMxhijvzPz7U1rR9GWxfWFP9Fm N5wttLneaLSA9lY2F8ElQSL++mPhIeV4l61l3vjSVFYh8tbrH9uhuH55LSdS19685t+7 9kDSHBpUGKFar/lwNSsC4BaNnDn71u/BqmOyElWycmo6dg8XiSVwj0YutXjgXw3M8B/U +020h5++e7Ik7I/srmj6fhR1RXnehYUJc8u4yYh87SA1okVNVFD7eE5uTG0LwQpQSW0f RWvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=d/qnTZeO6/zeeOj3JJ0Fesvkz/ASGCfcuV1CEBTmLnI=; b=RGe0QevugnERm5TuAYVa2676Vnwb9zr/Xh+H3lD6XcrEHvEKW2Pyo7qBiGJkp2YYi8 wUx6xxyUfT/aMzaSswN6Y04V3LMNOvagthgfW9O61oVt6kNS5Y5yJ9pWY8ZihYDHY0MR PkI1SxCGtlXpOQTYeBD0BXv+exnoLMBYQ/EMS2YCGdRJBpnU0NyR/lJVLfsMGIj0URj2 z3QW1vbEE5KMUSEY+HDEA3aNSRDC041gqOGHezxX3VhpvvySJLDkwE+edyUtC9Fehj9F ldmj7GO38xJlc6Vj7Y2Gmaa83eNGtZHhlDy3MM0fwRK7US28C7Vfpmoq7AgIuFD7GglV D9pQ== X-Gm-Message-State: APjAAAUvzgwQ2DvHHqQQO5RUENx/k6CDMghKpNUfDgAQTHS8E0VjSH3/ a0XxaFwACxdzCFkwIyoSBDUp1G6W69g= X-Google-Smtp-Source: APXvYqz4Z9SeUswi6o+ITj8LA+QYr+QTqjfFDmf+EDa40sYo2SmpuVHI6Rj6OKXPvQYqCGt5m7b//A== X-Received: by 2002:a5d:6b88:: with SMTP id n8mr10164198wrx.288.1576766441013; Thu, 19 Dec 2019 06:40:41 -0800 (PST) Received: from localhost ([88.98.246.218]) by smtp.gmail.com with ESMTPSA id n16sm6722758wro.88.2019.12.19.06.40.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Dec 2019 06:40:40 -0800 (PST) From: luca.boccassi@gmail.com To: Shweta Choudaha Cc: Xiaolong Ye , dpdk stable Date: Thu, 19 Dec 2019 14:34:15 +0000 Message-Id: <20191219143447.21506-108-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191219143447.21506-1-luca.boccassi@gmail.com> References: <20191219143447.21506-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/igb: fix PHY status if PHY reset is not blocked' has been queued to LTS release 17.11.10 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi, FYI, your patch has been queued to LTS release 17.11.10 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 12/21/19. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Thanks. Luca Boccassi --- >From 3a35b9f9696eb4448019fe8c25c76148df0e974a Mon Sep 17 00:00:00 2001 From: Shweta Choudaha Date: Thu, 16 May 2019 23:03:31 +0100 Subject: [PATCH] net/igb: fix PHY status if PHY reset is not blocked [ upstream commit 260dd6952600b5b44d0a1ce70a582116e6bd74fa ] When PHY reset is blocked as is the case when BMC is connected via NC-SI do not set GO_LINKD bit in PHY power management register in dev_stop as this will disconnect the PHY. Also, in dev_close clear the GO_LINKD bit only if PHY reset is not blocked Fixes: 3af34dec0b41 ("igb: force phy power up/down") Signed-off-by: Shweta Choudaha Reviewed-by: Xiaolong Ye --- drivers/net/e1000/igb_ethdev.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c index 4378f08209..cef6fded96 100644 --- a/drivers/net/e1000/igb_ethdev.c +++ b/drivers/net/e1000/igb_ethdev.c @@ -1557,8 +1557,9 @@ eth_igb_stop(struct rte_eth_dev *dev) igb_pf_reset_hw(hw); E1000_WRITE_REG(hw, E1000_WUC, 0); - /* Set bit for Go Link disconnect */ - if (hw->mac.type >= e1000_82580) { + /* Set bit for Go Link disconnect if PHY reset is not blocked */ + if (hw->mac.type >= e1000_82580 && + (e1000_check_reset_block(hw) != E1000_BLK_PHY_RESET)) { uint32_t phpm_reg; phpm_reg = E1000_READ_REG(hw, E1000_82580_PHY_POWER_MGMT); @@ -1632,8 +1633,9 @@ eth_igb_close(struct rte_eth_dev *dev) igb_release_manageability(hw); igb_hw_control_release(hw); - /* Clear bit for Go Link disconnect */ - if (hw->mac.type >= e1000_82580) { + /* Clear bit for Go Link disconnect if PHY reset is not blocked */ + if (hw->mac.type >= e1000_82580 && + (e1000_check_reset_block(hw) != E1000_BLK_PHY_RESET)) { uint32_t phpm_reg; phpm_reg = E1000_READ_REG(hw, E1000_82580_PHY_POWER_MGMT); -- 2.20.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2019-12-19 14:32:30.611022045 +0000 +++ 0108-net-igb-fix-PHY-status-if-PHY-reset-is-not-blocked.patch 2019-12-19 14:32:26.253300760 +0000 @@ -1,15 +1,16 @@ -From 260dd6952600b5b44d0a1ce70a582116e6bd74fa Mon Sep 17 00:00:00 2001 +From 3a35b9f9696eb4448019fe8c25c76148df0e974a Mon Sep 17 00:00:00 2001 From: Shweta Choudaha Date: Thu, 16 May 2019 23:03:31 +0100 Subject: [PATCH] net/igb: fix PHY status if PHY reset is not blocked +[ upstream commit 260dd6952600b5b44d0a1ce70a582116e6bd74fa ] + When PHY reset is blocked as is the case when BMC is connected via NC-SI do not set GO_LINKD bit in PHY power management register in dev_stop as this will disconnect the PHY. Also, in dev_close clear the GO_LINKD bit only if PHY reset is not blocked Fixes: 3af34dec0b41 ("igb: force phy power up/down") -Cc: stable@dpdk.org Signed-off-by: Shweta Choudaha Reviewed-by: Xiaolong Ye @@ -18,10 +19,10 @@ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c -index ce7c9e6646..53e83d5ec2 100644 +index 4378f08209..cef6fded96 100644 --- a/drivers/net/e1000/igb_ethdev.c +++ b/drivers/net/e1000/igb_ethdev.c -@@ -1468,8 +1468,9 @@ eth_igb_stop(struct rte_eth_dev *dev) +@@ -1557,8 +1557,9 @@ eth_igb_stop(struct rte_eth_dev *dev) igb_pf_reset_hw(hw); E1000_WRITE_REG(hw, E1000_WUC, 0); @@ -33,7 +34,7 @@ uint32_t phpm_reg; phpm_reg = E1000_READ_REG(hw, E1000_82580_PHY_POWER_MGMT); -@@ -1544,8 +1545,9 @@ eth_igb_close(struct rte_eth_dev *dev) +@@ -1632,8 +1633,9 @@ eth_igb_close(struct rte_eth_dev *dev) igb_release_manageability(hw); igb_hw_control_release(hw);