Skip to contentSkip to conversation

net: ftgmac100: Fixed NC-SI PHY device cannot get

PATCH In review Jacky Chou 2 participants 2 messages Jun 28, 2024 – Sep 9, 2024 Network drivers

lore
Share & tools
lore

Jacky Chou

author
#0 lore raw

PATCH 1/1 net: ftgmac100: Fixed NC-SI PHY device cannot get

The NC-SI interface does not need the MDIO bus and the NC-SI PHY device cannot get from dm_eth_phy_connect. Therefore, use phy_connect directly here.

---
 drivers/net/ftgmac100.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ftgmac100.c +1 -1
index 9b536fd5ab..256a519020 100644
@@ -223,7 +223,7 @@ static int ftgmac100_phy_init(struct udevice *dev)
 	struct phy_device *phydev;
 	int ret;
 
-	if (IS_ENABLED(CONFIG_DM_MDIO))
+	if (IS_ENABLED(CONFIG_DM_MDIO) && priv->phy_mode != PHY_INTERFACE_MODE_NCSI)
 		phydev = dm_eth_phy_connect(dev);
 	else
 		phydev = phy_connect(priv->bus, priv->phy_addr, dev, priv->phy_mode);
Signature · 1 line
2.25.1