linux/drivers/net
Vladimir Oltean 70edfae15a net: mscc: ocelot: offload VLAN mangle action to VCAP IS1
The VCAP_IS1_ACT_VID_REPLACE_ENA action, from the VCAP IS1 ingress TCAM,
changes the classified VLAN.

We are only exposing this ability for switch ports that are under VLAN
aware bridges. This is because in standalone ports mode and under a
bridge with vlan_filtering=0, the ocelot driver configures the switch to
operate as VLAN-unaware, so the classified VLAN is not derived from the
802.1Q header from the packet, but instead is always equal to the
port-based VLAN ID of the ingress port. We _can_ still change the
classified VLAN for packets when operating in this mode, but the end
result will most likely be a drop, since both the ingress and the egress
port need to be members of the modified VLAN. And even if we install the
new classified VLAN into the VLAN table of the switch, the result would
still not be as expected: we wouldn't see, on the output port, the
modified VLAN tag, but the original one, even though the classified VLAN
was indeed modified. This is because of how the hardware works: on
egress, what is pushed to the frame is a "port tag", which gives us the
following options:

- Tag all frames with port tag (derived from the classified VLAN)
- Tag all frames with port tag, except if the classified VLAN is 0 or
  equal to the native VLAN of the egress port
- No port tag

Needless to say, in VLAN-unaware mode we are disabling the port tag.
Otherwise, the existing VLAN tag would be ignored, and a second VLAN
tag (the port tag), holding the classified VLAN, would be pushed
(instead of replacing the existing 802.1Q tag). This is definitely not
what the user wanted when installing a "vlan modify" action.

So it is simply not worth bothering with VLAN modify rules under other
configurations except when the ports are fully VLAN-aware.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2020-10-11 11:19:04 -07:00
..
appletalk
arcnet
bonding net: core: introduce struct netdev_nested_priv for nested interface infrastructure 2020-09-28 15:00:15 -07:00
caif caif_virtio: Remove redundant initialization of variable err 2020-10-01 18:46:16 -07:00
can can: xilinx_can: Fix incorrect variable and initialize with a default value 2020-10-07 23:18:34 +02:00
dsa net: dsa: rtl8366rb: Roof MTU for switch 2020-10-10 11:25:05 -07:00
ethernet net: mscc: ocelot: offload VLAN mangle action to VCAP IS1 2020-10-11 11:19:04 -07:00
fddi fddi/skfp: Avoid the use of one-element array 2020-09-29 13:27:43 -07:00
fjes
hamradio
hippi
hyperv
ieee802154 genetlink: move to smaller ops wherever possible 2020-10-02 19:11:11 -07:00
ipa net: ipa: fix two comments 2020-09-28 18:34:56 -07:00
ipvlan
mdio net: phy: Move of_mdio from drivers/of to drivers/net/mdio 2020-10-10 10:55:05 -07:00
netdevsim devlink: Add devlink reload limit option 2020-10-09 12:06:52 -07:00
pcs net: pcs-lynx: add support for 10GBASER 2020-09-24 19:49:36 -07:00
phy Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-10-05 18:40:01 -07:00
plip
ppp
slip
team Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-10-05 18:40:01 -07:00
usb net: usbnet: remove driver version 2020-10-10 10:42:36 -07:00
vmxnet3 vmxnet3: fix cksum offload issues for non-udp tunnels 2020-09-25 16:41:40 -07:00
wan drivers/net/wan/hdlc_fr: Move the skb_headroom check out of fr_hard_header 2020-10-10 12:05:05 -07:00
wimax
wireguard Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-09-22 16:45:34 -07:00
wireless wireless-drivers-next patches for v5.10 2020-10-10 09:36:54 -07:00
xen-netback
bareudp.c bareudp: use dev_sw_netstats_rx_add() 2020-10-06 06:23:21 -07:00
dummy.c
eql.c
geneve.c geneve: use dev_sw_netstats_rx_add() 2020-10-06 06:23:21 -07:00
gtp.c gtp: use dev_sw_netstats_rx_add() 2020-10-06 06:23:21 -07:00
ifb.c
Kconfig
LICENSE.SRC
loopback.c
macsec.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-10-08 15:44:50 -07:00
macvlan.c
macvtap.c
Makefile
mdio.c
mii.c
net_failover.c
netconsole.c
nlmon.c
ntb_netdev.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tap.c
thunderbolt.c
tun.c
veth.c
virtio_net.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-10-05 18:40:01 -07:00
vrf.c
vsockmon.c
vxlan.c vxlan: use dev_sw_netstats_rx_add() 2020-10-06 06:23:21 -07:00
xen-netfront.c