summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2018-11-19 16:23:20 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2018-11-19 16:25:57 +0100
commit8b3633b261e50c6c96cefaa6e7f4acd26e8c2951 (patch)
treea0e82cb723946ce508a5f671438c5fbaeceb5678
parent68be59ad3b65463ae719b1ab71cb9d84b6f573a1 (diff)
downloadbarebox-8b3633b261e50c6c96cefaa6e7f4acd26e8c2951.tar.gz
barebox-8b3633b261e50c6c96cefaa6e7f4acd26e8c2951.tar.xz
net: cpsw: support "phy-handle" and deprecate "phy_id"
Upstream dts files changed to the generic binding for mii phys, so we have to support it in barebox aswell. The barebox internal device trees haven't been changed, so support them until all have changed. We print a warning to add some motivation to change. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
-rw-r--r--drivers/net/cpsw.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/cpsw.c b/drivers/net/cpsw.c
index c6fc21dc54..8bb2c9f2a3 100644
--- a/drivers/net/cpsw.c
+++ b/drivers/net/cpsw.c
@@ -1093,8 +1093,8 @@ static int cpsw_probe_dt(struct cpsw_priv *priv)
if (!of_find_node_by_name(child, "fixed-link")) {
ret = of_property_read_u32_array(child, "phy_id", phy_id, 2);
- if (ret)
- return ret;
+ if (!ret)
+ dev_warn(dev, "phy_id is deprecated, use phy-handle\n");
}
slave->dev.device_node = child;