* [PATCH net] net: dsa: motorcomm: Reread port flags on bridge joining
@ 2026-11-08 21:03 David Yang
2026-11-08 21:06 ` netdev-bot+sinfo
0 siblings, 1 reply; 2+ messages in thread
From: David Yang @ 2026-11-08 21:03 UTC (permalink / raw)
To: netdev
Cc: David Yang, Andrew Lunn, Vladimir Oltean, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni, linux-kernel
DSA replays neither BR_ISOLATED nor BR_HAIRPIN_MODE on join (e.g. a LAG
member rejoining its bond), so the cached flags survive into the next
bridge join and program stale hairpin and port isolation state. Sync
them from the bridge port.
Fixes: 186623f4aa72 ("net: dsa: yt921x: Add support for Motorcomm YT921x")
Signed-off-by: David Yang <mmyangfl@gmail.com>
---
drivers/net/dsa/motorcomm/chip.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/net/dsa/motorcomm/chip.c b/drivers/net/dsa/motorcomm/chip.c
index 33e5fc127244..fcc3a299ed66 100644
--- a/drivers/net/dsa/motorcomm/chip.c
+++ b/drivers/net/dsa/motorcomm/chip.c
@@ -1405,6 +1405,9 @@ yt921x_dsa_port_bridge_join(struct dsa_switch *ds, int port,
struct netlink_ext_ack *extack)
{
struct yt921x_priv *priv = dsa_to_yt921x_priv(ds);
+ struct yt921x_port *pp = &priv->ports[port];
+ struct net_device *brport_dev;
+ struct dsa_port *dp;
u16 ports_mask;
int res;
@@ -1414,7 +1417,12 @@ yt921x_dsa_port_bridge_join(struct dsa_switch *ds, int port,
ports_mask = dsa_bridge_ports(ds, bridge.dev);
ports_mask |= priv->cpu_ports_mask;
+ dp = dsa_to_port(ds, port);
+ brport_dev = dsa_port_to_bridge_port(dp);
+
mutex_lock(&priv->reg_lock);
+ pp->isolated = br_port_flag_is_set(brport_dev, BR_ISOLATED);
+ pp->hairpin = br_port_flag_is_set(brport_dev, BR_HAIRPIN_MODE);
res = yt921x_bridge_join(priv, port, ports_mask);
mutex_unlock(&priv->reg_lock);
--
2.53.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH net] net: dsa: motorcomm: Reread port flags on bridge joining
2026-11-08 21:03 [PATCH net] net: dsa: motorcomm: Reread port flags on bridge joining David Yang
@ 2026-11-08 21:06 ` netdev-bot+sinfo
0 siblings, 0 replies; 2+ messages in thread
From: netdev-bot+sinfo @ 2026-11-08 21:06 UTC (permalink / raw)
To: David Yang
Cc: netdev, Andrew Lunn, Vladimir Oltean, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni, linux-kernel
Hi!
This is an automated message. This series looks like a fix, but its
commit messages seem to be missing some information:
- How the issue was discovered, e.g. hit in production, hit during
development, syzbot report, manual code inspection, LLM or static
analysis tool scan.
- Whether the issue was actually triggered, or is only theoretical
(e.g. found by code inspection). If it was triggered please include
the symptoms, like the stack trace or error messages.
Please do not repost the series just to address the above. Instead,
reply to this email with the missing information, so that reviewers
can take it into account. If the series needs another revision for
other reasons, please include the information in the commit messages
then.
The evaluation is done by an LLM so it may be wrong, if you think
that is the case please reply and explain.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-11-08 21:06 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-08 21:03 [PATCH net] net: dsa: motorcomm: Reread port flags on bridge joining David Yang
2026-11-08 21:06 ` netdev-bot+sinfo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®