[PATCH] netdev/phy: skip disabled mdio-mux nodes

Timur Tabi timur at freescale.com
Wed Aug 8 03:04:00 EST 2012


David Daney wrote:
> Although this will get the job done, I don't think it is the cleanest 
> approach.
> 
> Would it be better to create a new iterator 
> (for_each_available_child_of_node perhaps) that skips the unavailable 
> nodes?  This seems like a general problem that is not restricted to mdio 
> multiplexers.

You're probably right, but this is how it's normally done.  If you're
going to scan child nodes manually, you have to skip disabled nodes.

If someone else wants to implement for_each_available_child_of_node(), I'm
all for it, but such a patch would not be merged until 3.7.  I was hoping
to have my patch applied to 3.6, since it fixes a real bug.

-- 
Timur Tabi
Linux kernel developer at Freescale



More information about the devicetree-discuss mailing list