Commit 9eab3fdb authored by Shyam Sundar S K's avatar Shyam Sundar S K Committed by David S. Miller
Browse files

net: amd-xgbe: Fix network fluctuations when using 1G BELFUSE SFP



Frequent link up/down events can happen when a Bel Fuse SFP part is
connected to the amd-xgbe device. Try to avoid the frequent link
issues by resetting the PHY as documented in Bel Fuse SFP datasheets.

Fixes: e722ec82 ("amd-xgbe: Update the BelFuse quirk to support SGMII")
Co-developed-by: default avatarSudheesh Mavila <sudheesh.mavila@amd.com>
Signed-off-by: default avatarSudheesh Mavila <sudheesh.mavila@amd.com>
Signed-off-by: default avatarShyam Sundar S K <Shyam-sundar.S-k@amd.com>
Acked-by: default avatarTom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 84fe68eb
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -922,6 +922,9 @@ static bool xgbe_phy_belfuse_phy_quirks(struct xgbe_prv_data *pdata)
	if ((phy_id & 0xfffffff0) != 0x03625d10)
		return false;

	/* Reset PHY - wait for self-clearing reset bit to clear */
	genphy_soft_reset(phy_data->phydev);

	/* Disable RGMII mode */
	phy_write(phy_data->phydev, 0x18, 0x7007);
	reg = phy_read(phy_data->phydev, 0x18);