From: Vladimir Oltean <olteanv@gmail.com>
To: Arun.Ramadoss@microchip.com
Cc: andrew@lunn.ch, linux-kernel@vger.kernel.org,
UNGLinuxDriver@microchip.com, vivien.didelot@gmail.com,
linux@armlinux.org.uk, f.fainelli@gmail.com, kuba@kernel.org,
edumazet@google.com, pabeni@redhat.com, netdev@vger.kernel.org,
Woojung.Huh@microchip.com, davem@davemloft.net
Subject: Re: [Patch RFC net-next 2/4] net: dsa: microchip: lan937x: remove vlan_filtering_is_global flag
Date: Wed, 3 Aug 2022 14:07:23 +0300 [thread overview]
Message-ID: <20220803110723.hym43imgsnnrgdnj@skbuf> (raw)
In-Reply-To: <1fe46b15172ff82125c46369d9ed235f67ed5afe.camel@microchip.com>
On Tue, Aug 02, 2022 at 04:09:35PM +0000, Arun.Ramadoss@microchip.com wrote:
> I have done some study on this SW_VLAN_ENABLE bit. By default the pvid
> of the port is 1 and vlan port membership (0xNA04) is 0xff. So if the
> bit is 0, then unknown dest addr packets are broadcasted which is the
> default behaviour of switch.
> Now consider when the bit is 1,
> - If the invalid vlan packet is received, then based on drop invalid
> vid or unknown vid forward bit, packets are discarded or forwarded.
> - If the valid vlan packet is received, then broadcast to ports in vlan
> port membership list.
> The port membership register set using the ksz9477_cfg_port_member
> function.
> In summary, I infer that we can enable this bit in the port_setup and
> based on the port membership packets can be forwarded. Is my
> understanding correct?
> Can I remove this patch from this series and submit as the separate
> one?
I'm not sure that the switch's capabilities are quite in line with the
Linux kernel expectations if you always force the 802.1Q VLAN Enable bit
to true.
I am looking at Table 4-8: VLAN forwarding from the KSZ9563 datasheet,
and it says that when the "Unknown VID forward" bit is set and we are in
VLAN enable mode, packets are forwarded to the Unknown VID packet
forward list regardless of ALU match (which is "don't care" in this table).
In essence this is because the switch failed to resolve the unknown VID
to a FID. Other switches have a default FID for this case, but it
doesn't appear to hold true for KSZ.
The last thing you want is for packets under a VLAN-unaware bridge to be
always flooded to the ports in the Unknown VID packet forward list, and
bypass ALU lookups.
next prev parent reply other threads:[~2022-08-03 11:07 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-29 15:17 [Patch RFC net-next 0/4] net: dsa: microchip: vlan configuration for bridge_vlan_unaware ports Arun Ramadoss
2022-07-29 15:17 ` [Patch RFC net-next 1/4] net: dsa: microchip: modify vlan_add function prototype Arun Ramadoss
2022-08-02 10:32 ` Vladimir Oltean
2022-08-02 13:58 ` Arun.Ramadoss
2022-07-29 15:17 ` [Patch RFC net-next 2/4] net: dsa: microchip: lan937x: remove vlan_filtering_is_global flag Arun Ramadoss
2022-08-02 10:40 ` Vladimir Oltean
2022-08-02 16:09 ` Arun.Ramadoss
2022-08-03 11:07 ` Vladimir Oltean [this message]
2022-07-29 15:17 ` [Patch RFC net-next 3/4] net: dsa: microchip: common ksz pvid get and set function Arun Ramadoss
2022-08-02 10:45 ` Vladimir Oltean
2022-08-04 2:05 ` Florian Fainelli
2022-07-29 15:17 ` [Patch RFC net-next 4/4] net: dsa: microchip: use private pvid for bridge_vlan_unwaware Arun Ramadoss
2022-08-02 10:59 ` Vladimir Oltean
2022-08-02 14:40 ` Arun.Ramadoss
2022-08-03 14:49 ` Vladimir Oltean
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220803110723.hym43imgsnnrgdnj@skbuf \
--to=olteanv@gmail.com \
--cc=Arun.Ramadoss@microchip.com \
--cc=UNGLinuxDriver@microchip.com \
--cc=Woojung.Huh@microchip.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=vivien.didelot@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox