linux/tools/testing/selftests/drivers/net/mlxsw
Ido Schimmel 979b9b251a mlxsw: spectrum: Clear VLAN filters during port initialization
When a port is created, its VLAN filters are not cleared by the
firmware. This causes tagged packets to be later dropped by the ingress
STP filters, which default to DISCARD state.

The above did not matter much until commit b5ce611fd9 ("mlxsw:
spectrum: Add devlink-trap support") where we exposed the drop reason to
users.

Without this patch, the drop reason users will see is not consistent. If
a port is enslaved to a VLAN-aware bridge and a packet with an invalid
VLAN tries to ingress the bridge, it will be dropped due to ingress STP
filter. If the VLAN is later enabled and then disabled, the packet will
be dropped by the ingress VLAN filter despite the above being a
seemingly NOP operation.

Fix this by clearing all the VLAN filters during port initialization.
Adjust the test accordingly.

Fixes: b5ce611fd9 ("mlxsw: spectrum: Add devlink-trap support")
Reported-by: Alex Kushnarov <alexanderk@mellanox.com>
Tested-by: Alex Kushnarov <alexanderk@mellanox.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-09-27 20:33:19 +02:00
..
spectrum selftests: forwarding: devlink_lib: Avoid double sourcing of lib.sh 2019-03-28 17:20:52 -07:00
spectrum-2 selftests: forwarding: devlink_lib: Avoid double sourcing of lib.sh 2019-03-28 17:20:52 -07:00
blackhole_routes.sh selftests: mlxsw: Add a test for blackhole routes 2019-02-06 14:24:05 -08:00
devlink_trap_l2_drops.sh mlxsw: spectrum: Clear VLAN filters during port initialization 2019-09-27 20:33:19 +02:00
devlink_trap.sh selftests: mlxsw: Add a test case for devlink-trap 2019-08-21 12:58:39 -07:00
extack.sh selftests: mlxsw: extack: Test VLAN add on a port device 2018-12-12 16:34:22 -08:00
fib_offload.sh selftests: mlxsw: Add a test for FIB offload indication 2019-06-18 09:45:37 -07:00
mirror_gre_scale.sh selftests: mlxsw: Add scale test for mirror-to-gretap 2018-06-30 22:06:16 +09:00
mirror_gre.sh selftests: mlxsw: Add mlxsw-specific test for mirror to gretap 2018-07-07 20:29:34 +09:00
one_armed_router.sh selftests: mlxsw: Add one-armed router test 2018-12-04 08:36:36 -08:00
qos_dscp_bridge.sh selftests: mlxsw: Fix local variable declarations in DSCP tests 2019-07-31 08:47:13 -07:00
qos_dscp_router.sh selftests: mlxsw: Add a test for leftover DSCP rule 2019-07-31 08:47:13 -07:00
qos_ets_strict.sh selftests: mlxsw: Add a new test for strict priority 2019-03-28 17:20:53 -07:00
qos_lib.sh selftests: mlxsw: Add qos_lib.sh 2019-03-28 17:20:52 -07:00
qos_mc_aware.sh selftests: mlxsw: Fix typo in qos_mc_aware.sh 2019-07-24 14:51:10 -07:00
router_scale.sh selftests: mlxsw: Add router test 2018-06-30 22:06:15 +09:00
rtnetlink.sh selftests: mlxsw: Test nexthop offload indication 2019-06-12 11:08:14 -07:00
tc_flower_scale.sh selftests: mlxsw: Add tc flower scale test 2018-06-30 22:06:15 +09:00
vxlan_fdb_veto.sh selftests: mlxsw: Test veto of unsupported VXLAN FDBs 2019-01-17 15:18:47 -08:00
vxlan_flooding.sh selftests: mlxsw: Add a test for VxLAN flooding 2018-11-19 17:59:44 -08:00
vxlan.sh selftests: mlxsw: Add a test case for VLAN addition error flow 2019-01-08 16:53:54 -05:00