]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
net: ftgmac100: Fixed NC-SI PHY device cannot get
authorJacky Chou <jacky_chou@aspeedtech.com>
Fri, 28 Jun 2024 07:14:45 +0000 (15:14 +0800)
committerLeo Yu-Chi Liang <ycliang@andestech.com>
Wed, 11 Sep 2024 12:34:35 +0000 (20:34 +0800)
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.

Signed-off-by: Jacky Chou <jacky_chou@aspeedtech.com>
Acked-by: Leo Yu-Chi Liang <ycliang@andestech.com>
drivers/net/ftgmac100.c

index 853a9913d24e1bac280a100df2d180435127702e..392016141c41746e281f26e16b0dcdfdc54682fa 100644 (file)
@@ -222,7 +222,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);