[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20211012173709.3453585-2-Shyam-sundar.S-k@amd.com>
Date: Tue, 12 Oct 2021 23:07:09 +0530
From: Shyam Sundar S K <Shyam-sundar.S-k@....com>
To: Tom Lendacky <thomas.lendacky@....com>,
"David S . Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>
CC: <netdev@...r.kernel.org>, <Raju.Rangoju@....com>,
Shyam Sundar S K <Shyam-sundar.S-k@....com>,
Sudheesh Mavila <sudheesh.mavila@....com>
Subject: [PATCH 2/2] net: amd-xgbe: Enable RRC when auto-negotiation is enabled
Receiver Reset Cycle (RRC) is only required when the
auto-negotiation is enabled.
Co-developed-by: Sudheesh Mavila <sudheesh.mavila@....com>
Signed-off-by: Sudheesh Mavila <sudheesh.mavila@....com>
Signed-off-by: Shyam Sundar S K <Shyam-sundar.S-k@....com>
---
drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c b/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c
index 4465af9b72cf..1a11407e277c 100644
--- a/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c
+++ b/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c
@@ -2642,7 +2642,9 @@ static int xgbe_phy_link_status(struct xgbe_prv_data *pdata, int *an_restart)
/* No link, attempt a receiver reset cycle */
if (phy_data->rrc_count++ > XGBE_RRC_FREQUENCY) {
phy_data->rrc_count = 0;
- xgbe_phy_rrc(pdata);
+ /* RRC is required only if auto-negotiation is enabled */
+ if (pdata->phy.autoneg == AUTONEG_ENABLE)
+ xgbe_phy_rrc(pdata);
}
return 0;
--
2.25.1
Powered by blists - more mailing lists