diff options
author | Bin Meng <bmeng.cn@gmail.com> | 2021-03-14 20:14:47 +0800 |
---|---|---|
committer | Priyanka Jain <priyanka.jain@nxp.com> | 2021-04-15 14:22:17 +0530 |
commit | 33aad0b0920987ef74b15bc413058a3285d28bec (patch) | |
tree | 0603de04552ecb4a65650bd626141c2ed36f1716 /net/mdio-uclass.c | |
parent | 173c66bf9c0cfefd0ff69f0939c95900340d0988 (diff) | |
download | u-boot-33aad0b0920987ef74b15bc413058a3285d28bec.zip u-boot-33aad0b0920987ef74b15bc413058a3285d28bec.tar.gz u-boot-33aad0b0920987ef74b15bc413058a3285d28bec.tar.bz2 |
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 <bmeng.cn@gmail.com>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
Diffstat (limited to 'net/mdio-uclass.c')
-rw-r--r-- | net/mdio-uclass.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/mdio-uclass.c b/net/mdio-uclass.c index 5da984c..2a9533c 100644 --- a/net/mdio-uclass.c +++ b/net/mdio-uclass.c @@ -11,6 +11,7 @@ #include <miiphy.h> #include <dm/device-internal.h> #include <dm/device_compat.h> +#include <dm/of_extra.h> #include <dm/uclass-internal.h> #include <linux/compat.h> @@ -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; } |