Skip to content

Commit

Permalink
netdev/phy: skip disabled mdio-mux nodes
Browse files Browse the repository at this point in the history
The mdio-mux driver scans all child mdio nodes, without regard to whether
the node is actually used.  Some device trees include all possible
mdio-mux nodes and rely on the boot loader to disable those that are not
present, based on some run-time configuration.  Those nodes need to be
skipped.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Timur Tabi authored and David S. Miller committed Aug 20, 2012
1 parent 3296193 commit 61abcb7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/phy/mdio-mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ int mdio_mux_init(struct device *dev,
pb->mii_bus = parent_bus;

ret_val = -ENODEV;
for_each_child_of_node(dev->of_node, child_bus_node) {
for_each_available_child_of_node(dev->of_node, child_bus_node) {
u32 v;

r = of_property_read_u32(child_bus_node, "reg", &v);
Expand Down

0 comments on commit 61abcb7

Please sign in to comment.