Commit 5005b163 authored by Russell King's avatar Russell King Committed by David S. Miller

net: phylink: update PCS when changing interface during resolution

The only PHYs that are used with phylink which change their interface
are the BCM84881 and MV88X3310 family, both of which only change their
interface modes on link-up events.  This will break when drivers are
converted to split-PCS.  Fix this.
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarRussell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 16319a7d
...@@ -629,8 +629,15 @@ static void phylink_resolve(struct work_struct *w) ...@@ -629,8 +629,15 @@ static void phylink_resolve(struct work_struct *w)
phylink_link_down(pl); phylink_link_down(pl);
cur_link_state = false; cur_link_state = false;
} }
phylink_pcs_config(pl, false, &link_state);
pl->link_config.interface = link_state.interface;
} else {
/* The interface remains unchanged, only the speed,
* duplex or pause settings have changed. Call the
* old mac_config() method to configure the MAC/PCS.
*/
phylink_mac_config(pl, &link_state);
} }
phylink_mac_config(pl, &link_state);
} }
if (link_state.link != cur_link_state) { if (link_state.link != cur_link_state) {
......
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