[PATCH 2/2] net: tsec: read the phy-mode property as fallback to phy-connection-type
Vladimir Oltean
vladimir.oltean at nxp.com
Sat Sep 18 14:46:55 CEST 2021
The two should be equivalent, but at the moment some platforms
(ls1021a-tsn.dts) use phy-mode only, which is not parsed.
Signed-off-by: Vladimir Oltean <vladimir.oltean at nxp.com>
---
drivers/net/tsec.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/tsec.c b/drivers/net/tsec.c
index 809cf7e432e6..f0cf0a7559ab 100644
--- a/drivers/net/tsec.c
+++ b/drivers/net/tsec.c
@@ -884,6 +884,8 @@ int tsec_probe(struct udevice *dev)
priv->tbiaddr = tbiaddr;
phy_mode = dev_read_prop(dev, "phy-connection-type", NULL);
+ if (!phy_mode)
+ phy_mode = dev_read_prop(dev, "phy-mode", NULL);
if (phy_mode)
pdata->phy_interface = phy_get_interface_by_name(phy_mode);
if (pdata->phy_interface == -1)
--
2.25.1
More information about the U-Boot
mailing list