Re: [PATCH net 2/2] net: dsa: realtek: rtl8365mb: keep the neutral PVID in VLAN-unaware bridges
From: Stijn Cleynhens
Date: Fri Nov 06 2026 - 10:03:44 EST
On Wed, Nov 04, 2026 at 04:57:44PM +0100, Alvin Šipraga wrote:
> This part threw me off a bit. What do you mean by "VID of the bridge
> entries"? If the neutral PVID is programmed on the port of a
> VLAN-unaware bridge, I would expect all untagged frames to be classified
> VID=0. And with IVL this should be classified local to the bridge. Is
> that what you want to say, or am I missing something?
Yes, that is what I meant: untagged frames go to VID 0, the VID that DSA
uses for the FDB and MDB entries of a VLAN-unaware bridge. One detail:
it is the per-bridge EFID that keeps the lookup local to the bridge; IVL
makes the VID part of the key. I reworded it in v2.
> Please separate the variables on their own lines.
> I think an else { pvid = 0; } would be more explicit than setting it
> upstairs, but it's a nitpick.
Both done in v2.
> Can we unify _set and _clear somehow? The code gets quite confusing with
> the two variants, and it seems now that with the vlan_filtering
> argument, you can unify the logic.
Agreed. v2 replaces both with rtl8365mb_vlan_pvid_port_commit(), which
takes the target VID (0 for the neutral PVID) and the filtering state,
and is the only place that sets the frame filter, so
rtl8365mb_port_vlan_filtering() no longer touches it. Tested again on an
RTL8367S and an RTL8367S-VB.
Thanks for the review,
Stijn