mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-02-27 09:23:07 -05:00
net: prestera: use phylink_pcs_change() to report PCS link change events
Use phylink_pcs_change() when reporting changes in PCS link state to phylink as the interrupts are informing us about changes to the PCS state. Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Reviewed-by: Simon Horman <horms@kernel.org> Link: https://lore.kernel.org/r/E1s0OGx-009hgr-NP@rmk-PC.armlinux.org.uk Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
21c8e45acb
commit
e47e5e85da
@@ -821,7 +821,7 @@ static void prestera_port_handle_event(struct prestera_switch *sw,
|
||||
|
||||
if (port->state_mac.oper) {
|
||||
if (port->phy_link)
|
||||
phylink_mac_change(port->phy_link, true);
|
||||
phylink_pcs_change(&port->phylink_pcs, true);
|
||||
else
|
||||
netif_carrier_on(port->dev);
|
||||
|
||||
@@ -829,7 +829,7 @@ static void prestera_port_handle_event(struct prestera_switch *sw,
|
||||
queue_delayed_work(prestera_wq, caching_dw, 0);
|
||||
} else {
|
||||
if (port->phy_link)
|
||||
phylink_mac_change(port->phy_link, false);
|
||||
phylink_pcs_change(&port->phylink_pcs, false);
|
||||
else if (netif_running(port->dev) && netif_carrier_ok(port->dev))
|
||||
netif_carrier_off(port->dev);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user