Skip to contentSkip to conversation

net: dsa: motorcomm: Stop MIB poll on link down

PATCH Applied David Yang 2 participants 2 messages Nov 8 – Nov 11

Subsystems (4)
lore
Share & tools
lore

David Yang

author maintainer
#0 lore raw

PATCH 1/1 net: dsa: motorcomm: Stop MIB poll on link down

The poll re-arms itself unconditionally, and link down only cancels the work non-sync, so a poll caught running kept polling every few seconds while the link was down.

Cancel the work synchronously so that the re-arm from a running poll is rejected.

Not carrying a fix tag - the existing behavior is harmless nevertheless.

---
 drivers/net/dsa/motorcomm/chip.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/net/dsa/motorcomm/chip.c +1 -2
index 33e5fc127244..758599ba0957 100644
@@ -1837,10 +1837,9 @@ yt921x_phylink_mac_link_down(struct phylink_config *config, unsigned int mode,
 	int port = dp->index;
 	int res;
 
-	/* No need to sync; port control block is hold until device remove */
 	pm = priv->ports[port].mib;
 	if (pm)
-		cancel_delayed_work(&pm->work);
+		cancel_delayed_work_sync(&pm->work);
 
 	mutex_lock(&priv->reg_lock);
 	res = yt921x_port_down(priv, port);
Signature · 1 line
2.53.0
#1 lore raw
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Quoted 8 lines · On Sun, 8 Nov 2026 18:40:34 +0800 you wrote:

The poll re-arms itself unconditionally, and link down only cancels the work non-sync, so a poll caught running kept polling every few seconds while the link was down.

Cancel the work synchronously so that the re-arm from a running poll is rejected.

[...]

Here is the summary with links:
- [net-next] net: dsa: motorcomm: Stop MIB poll on link down

    https://git.kernel.org/netdev/net-next/c/176da52a815e

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html