From: Bin Meng Date: Sun, 14 Mar 2021 12:14:47 +0000 (+0800) Subject: dm: mdio: Use ofnode_phy_is_fixed_link() API X-Git-Tag: v2025.01-rc5-pxa1908~1920^2~37 X-Git-Url: http://git.dujemihanovic.xyz/login.html?a=commitdiff_plain;h=33aad0b0920987ef74b15bc413058a3285d28bec;p=u-boot.git dm: mdio: Use ofnode_phy_is_fixed_link() API Switch to use the ofnode_phy_is_fixed_link() API which can support both the new and old DT bindings. Signed-off-by: Bin Meng Reviewed-by: Ramon Fried Reviewed-by: Vladimir Oltean Reviewed-by: Priyanka Jain --- diff --git a/net/mdio-uclass.c b/net/mdio-uclass.c index 5da984ca3f..2a9533c88b 100644 --- a/net/mdio-uclass.c +++ b/net/mdio-uclass.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include @@ -140,7 +141,7 @@ static struct phy_device *dm_eth_connect_phy_handle(struct udevice *ethdev, int i; if (CONFIG_IS_ENABLED(PHY_FIXED) && - ofnode_valid(dev_read_subnode(ethdev, "fixed-link"))) { + ofnode_phy_is_fixed_link(dev_ofnode(ethdev), NULL)) { phy = phy_connect(NULL, -1, ethdev, interface); goto out; }