summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/arc/emac_mdio.c
diff options
context:
space:
mode:
authorRomain Perier <romain.perier@gmail.com>2014-08-26 17:14:50 +0400
committerDavid S. Miller <davem@davemloft.net>2014-08-28 03:40:26 +0400
commit93e91b3dda17be19ecf52de2400a02c6469decfa (patch)
treec74ffabc1c714cf8d3094ba35572586a72ed8196 /drivers/net/ethernet/arc/emac_mdio.c
parentf15f44e0839793ea03ffef5bae532cd63d92948c (diff)
downloadlinux-93e91b3dda17be19ecf52de2400a02c6469decfa.tar.xz
ethernet: arc: mdio changes for future SoC glue layer devtree support
This is an api changes for the emac_mdio.c module. It will be required later when arc_emac_probe/arc_emac_remove will no longer use 'struct platform_device'. Signed-off-by: Romain Perier <romain.perier@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/arc/emac_mdio.c')
-rw-r--r--drivers/net/ethernet/arc/emac_mdio.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/ethernet/arc/emac_mdio.c b/drivers/net/ethernet/arc/emac_mdio.c
index 26ba2423f33a..d5ee986936da 100644
--- a/drivers/net/ethernet/arc/emac_mdio.c
+++ b/drivers/net/ethernet/arc/emac_mdio.c
@@ -100,7 +100,6 @@ static int arc_mdio_write(struct mii_bus *bus, int phy_addr,
/**
* arc_mdio_probe - MDIO probe function.
- * @pdev: Pointer to platform device.
* @priv: Pointer to ARC EMAC private data structure.
*
* returns: 0 on success, -ENOMEM when mdiobus_alloc
@@ -108,7 +107,7 @@ static int arc_mdio_write(struct mii_bus *bus, int phy_addr,
*
* Sets up and registers the MDIO interface.
*/
-int arc_mdio_probe(struct platform_device *pdev, struct arc_emac_priv *priv)
+int arc_mdio_probe(struct arc_emac_priv *priv)
{
struct mii_bus *bus;
int error;
@@ -124,9 +123,9 @@ int arc_mdio_probe(struct platform_device *pdev, struct arc_emac_priv *priv)
bus->read = &arc_mdio_read;
bus->write = &arc_mdio_write;
- snprintf(bus->id, MII_BUS_ID_SIZE, "%s", pdev->name);
+ snprintf(bus->id, MII_BUS_ID_SIZE, "%s", bus->name);
- error = of_mdiobus_register(bus, pdev->dev.of_node);
+ error = of_mdiobus_register(bus, priv->dev->of_node);
if (error) {
dev_err(priv->dev, "cannot register MDIO bus %s\n", bus->name);
mdiobus_free(bus);