Commit 575691b3 authored by Russell King's avatar Russell King Committed by David S. Miller

net: phylink: only restart AN if the link mode is using in-band AN

If we are not using in-band autonegotiation, there is no point passing
the request to restart autonegotiation on to the driver.
Signed-off-by: default avatarRussell King <rmk+kernel@armlinux.org.uk>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent a5440cbe
...@@ -429,7 +429,8 @@ static void phylink_mac_config_up(struct phylink *pl, ...@@ -429,7 +429,8 @@ static void phylink_mac_config_up(struct phylink *pl,
static void phylink_mac_pcs_an_restart(struct phylink *pl) static void phylink_mac_pcs_an_restart(struct phylink *pl)
{ {
if (pl->link_config.an_enabled && if (pl->link_config.an_enabled &&
phy_interface_mode_is_8023z(pl->link_config.interface)) { phy_interface_mode_is_8023z(pl->link_config.interface) &&
phylink_autoneg_inband(pl->cur_link_an_mode)) {
if (pl->pcs_ops) if (pl->pcs_ops)
pl->pcs_ops->pcs_an_restart(pl->config); pl->pcs_ops->pcs_an_restart(pl->config);
else else
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment