From: Timur Tabi <timur-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
To: Grant Likely
<grant.likely-s3s/WqlpOiPyB63q8FvJNQ@public.gmane.org>,
David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>,
<david.daney-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>,
<netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
<devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org>
Subject: [PATCH 2/2] [v2] netdev/phy: skip disabled mdio-mux nodes
Date: Tue, 14 Aug 2012 18:20:24 -0500 [thread overview]
Message-ID: <1344986424-14360-2-git-send-email-timur@freescale.com> (raw)
In-Reply-To: <1344986424-14360-1-git-send-email-timur-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
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-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
---
drivers/net/phy/mdio-mux.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c
index 5c12018..4d4d25e 100644
--- a/drivers/net/phy/mdio-mux.c
+++ b/drivers/net/phy/mdio-mux.c
@@ -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);
--
1.7.3.4
next prev parent reply other threads:[~2012-08-14 23:20 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-14 23:20 [PATCH 1/2] dt: introduce for_each_available_child_of_node, of_get_next_available_child Timur Tabi
[not found] ` <1344986424-14360-1-git-send-email-timur-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
2012-08-14 23:20 ` Timur Tabi [this message]
2012-08-20 9:16 ` [PATCH 2/2] [v2] netdev/phy: skip disabled mdio-mux nodes David Miller
2012-08-20 9:16 ` [PATCH 1/2] dt: introduce for_each_available_child_of_node, of_get_next_available_child David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1344986424-14360-2-git-send-email-timur@freescale.com \
--to=timur-kzfg59tc24xl57midrcfdg@public.gmane.org \
--cc=davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org \
--cc=david.daney-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org \
--cc=devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org \
--cc=grant.likely-s3s/WqlpOiPyB63q8FvJNQ@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).