[PATCH] net: phy: c45-tjaxx: add delay between MDIO write and read in soft_reset

Milos Reljin
2025-01-16T14:55:50Z

Add delay before first MDIO read following MDIO write in soft_reset
function. Without this, soft_reset fails and PHY init cannot complete.

Signed-off-by: Milos Reljin <milos_reljin@outlook.com>
---
drivers/net/phy/nxp-c45-tja11xx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/phy/nxp-c45-tja11xx.c b/drivers/net/phy/nxp-c45-tja11xx.c
index ade544bc007d..be0ca7b12dc3 100644
--- a/drivers/net/phy/nxp-c45-tja11xx.c
+++ b/drivers/net/phy/nxp-c45-tja11xx.c
@@ -1300,7 +1300,7 @@ static int nxp_c45_soft_reset(struct phy_device *phydev)
return phy_read_mmd_poll_timeout(phydev, MDIO_MMD_VEND1,
VEND1_DEVICE_CONTROL, ret,
!(ret & DEVICE_CONTROL_RESET), 20000,
- 240000, false);
+ 240000, true);
}

static int nxp_c45_cable_test_start(struct phy_device *phydev)
--
2.34.1