aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/of/of_mdio.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/of/of_mdio.c')
-rw-r--r--drivers/of/of_mdio.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/of/of_mdio.c b/drivers/of/of_mdio.c
index fb4a59830648..a3bf2122a8d5 100644
--- a/drivers/of/of_mdio.c
+++ b/drivers/of/of_mdio.c
@@ -323,11 +323,13 @@ int of_phy_register_fixed_link(struct device_node *np)
323 fixed_link_node = of_get_child_by_name(np, "fixed-link"); 323 fixed_link_node = of_get_child_by_name(np, "fixed-link");
324 if (fixed_link_node) { 324 if (fixed_link_node) {
325 status.link = 1; 325 status.link = 1;
326 status.duplex = of_property_read_bool(np, "full-duplex"); 326 status.duplex = of_property_read_bool(fixed_link_node,
327 "full-duplex");
327 if (of_property_read_u32(fixed_link_node, "speed", &status.speed)) 328 if (of_property_read_u32(fixed_link_node, "speed", &status.speed))
328 return -EINVAL; 329 return -EINVAL;
329 status.pause = of_property_read_bool(np, "pause"); 330 status.pause = of_property_read_bool(fixed_link_node, "pause");
330 status.asym_pause = of_property_read_bool(np, "asym-pause"); 331 status.asym_pause = of_property_read_bool(fixed_link_node,
332 "asym-pause");
331 of_node_put(fixed_link_node); 333 of_node_put(fixed_link_node);
332 return fixed_phy_register(PHY_POLL, &status, np); 334 return fixed_phy_register(PHY_POLL, &status, np);
333 } 335 }