netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: "David S. Miller" <davem@davemloft.net>
Cc: adi-buildroot-devel@lists.sourceforge.net,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	Guenter Roeck <linux@roeck-us.net>, Andrew Lunn <andrew@lunn.ch>
Subject: [PATCH -next 2/2] net: bfin_mac: Fix build error due to missed API change
Date: Sat,  9 Jan 2016 08:37:07 -0800	[thread overview]
Message-ID: <1452357427-30578-2-git-send-email-linux@roeck-us.net> (raw)
In-Reply-To: <1452357427-30578-1-git-send-email-linux@roeck-us.net>

Commit 7f854420fbfe ("phy: Add API for {un}registering an mdio device to
a bus") introduces an API to access mii_bus structures, but missed to
update the bfin_mac driver. This results in the following error message

drivers/net/ethernet/adi/bfin_mac.c: In function 'mii_probe':
drivers/net/ethernet/adi/bfin_mac.c:401:52: error:
	'struct mii_bus' has no member named 'phy_map'

Fixes: 7f854420fbfe ("phy: Add API for {un}registering an mdio device to a bus")
Cc: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/net/ethernet/adi/bfin_mac.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/adi/bfin_mac.c b/drivers/net/ethernet/adi/bfin_mac.c
index 8c5132624510..1281cae5b70f 100644
--- a/drivers/net/ethernet/adi/bfin_mac.c
+++ b/drivers/net/ethernet/adi/bfin_mac.c
@@ -398,7 +398,8 @@ static int mii_probe(struct net_device *dev, int phy_mode)
 
 	/* search for connected PHY device */
 	for (i = 0; i < PHY_MAX_ADDR; ++i) {
-		struct phy_device *const tmp_phydev = lp->mii_bus->phy_map[i];
+		struct phy_device *const tmp_phydev =
+			mdiobus_get_phy(lp->mii_bus, i);
 
 		if (!tmp_phydev)
 			continue; /* no PHY here... */
-- 
2.1.4

  reply	other threads:[~2016-01-09 16:37 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-09 16:37 [PATCH -next 1/2] net: bfin_mac: Fix error handling in probe function Guenter Roeck
2016-01-09 16:37 ` Guenter Roeck [this message]
2016-01-09 16:58 ` Andrew Lunn
2016-01-09 18:10   ` Guenter Roeck
2016-01-09 20:52     ` Andrew Lunn
2016-01-10 15:16       ` Guenter Roeck
2016-01-10 15:49         ` Andrew Lunn
2016-01-10 16:22           ` Guenter Roeck
2016-01-10 17:21             ` Andrew Lunn
2016-01-10 20:10               ` Guenter Roeck
2016-01-10 23:58                 ` Andrew Lunn
2016-01-11  8:43         ` Sudip Mukherjee
2016-01-11 16:23           ` Guenter Roeck

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=1452357427-30578-2-git-send-email-linux@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=adi-buildroot-devel@lists.sourceforge.net \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.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).