Skip to content

Commit

Permalink
net: mv643xx_eth: properly start/stop phy device
Browse files Browse the repository at this point in the history
When using phydev, it should be phy_start/phy_stop'ed properly. This
driver doesn't do that, so add the corresponding calls to port_start/
stop respectively.

Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
Acked-by: Mugunthan V N <mugunthanvnm@ti.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Sebastian Hesselbarth authored and David S. Miller committed Dec 17, 2013
1 parent be78cfc commit 5891115
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/net/ethernet/marvell/mv643xx_eth.c
Original file line number Diff line number Diff line change
Expand Up @@ -2080,6 +2080,7 @@ static void port_start(struct mv643xx_eth_private *mp)
mv643xx_eth_get_settings(mp->dev, &cmd);
phy_init_hw(mp->phy);
mv643xx_eth_set_settings(mp->dev, &cmd);
phy_start(mp->phy);
}

/*
Expand Down Expand Up @@ -2275,7 +2276,8 @@ static int mv643xx_eth_stop(struct net_device *dev)
del_timer_sync(&mp->rx_oom);

netif_carrier_off(dev);

if (mp->phy)
phy_stop(mp->phy);
free_irq(dev->irq, dev);

port_reset(mp);
Expand Down

0 comments on commit 5891115

Please sign in to comment.