aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorFlorian Fainelli <florian@openwrt.org>2012-02-12 20:23:23 -0500
committerDavid S. Miller <davem@davemloft.net>2012-02-13 16:04:09 -0500
commitb0c06e12b6f1dad480c459ddc5412a0fd8582201 (patch)
tree261f5edb91526a40f616949293c650ea10015667 /drivers/net
parentea51ade9398f3c94f63a25f512445ee7cbbbf284 (diff)
octeon: fix PHY name to match MDIO bus name
Commit "d6c25be: mdio-octeon: use an unique MDIO bus name" changed the octeon MDIO bus name from "0" to "mdio-octeon-0", change the PHY formatting logic to account for that name change, so that PHY connection on this bus succeeds. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/ethernet/octeon/octeon_mgmt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/octeon/octeon_mgmt.c b/drivers/net/ethernet/octeon/octeon_mgmt.c
index 212f43b308a..cd827ff4a02 100644
--- a/drivers/net/ethernet/octeon/octeon_mgmt.c
+++ b/drivers/net/ethernet/octeon/octeon_mgmt.c
@@ -670,7 +670,7 @@ static void octeon_mgmt_adjust_link(struct net_device *netdev)
670static int octeon_mgmt_init_phy(struct net_device *netdev) 670static int octeon_mgmt_init_phy(struct net_device *netdev)
671{ 671{
672 struct octeon_mgmt *p = netdev_priv(netdev); 672 struct octeon_mgmt *p = netdev_priv(netdev);
673 char phy_id[20]; 673 char phy_id[MII_BUS_ID_SIZE + 3];
674 674
675 if (octeon_is_simulation()) { 675 if (octeon_is_simulation()) {
676 /* No PHYs in the simulator. */ 676 /* No PHYs in the simulator. */
@@ -678,7 +678,7 @@ static int octeon_mgmt_init_phy(struct net_device *netdev)
678 return 0; 678 return 0;
679 } 679 }
680 680
681 snprintf(phy_id, sizeof(phy_id), PHY_ID_FMT, "0", p->port); 681 snprintf(phy_id, sizeof(phy_id), PHY_ID_FMT, "mdio-octeon-0", p->port);
682 682
683 p->phydev = phy_connect(netdev, phy_id, octeon_mgmt_adjust_link, 0, 683 p->phydev = phy_connect(netdev, phy_id, octeon_mgmt_adjust_link, 0,
684 PHY_INTERFACE_MODE_MII); 684 PHY_INTERFACE_MODE_MII);