]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Set vlan masks for all offloaded TC rules
authorJianbo Liu <jianbol@mellanox.com>
Sat, 25 Aug 2018 03:29:58 +0000 (03:29 +0000)
committerSaeed Mahameed <saeedm@mellanox.com>
Mon, 1 Oct 2018 17:58:00 +0000 (10:58 -0700)
commit9812df55ce0f8a4a740d7c49355003c5a18a10b7
tree250e7212e3545c67bb6c1994460e318e287d4534
parent89167969f081d9b10919f3db55dc9e0348f0b3d3
net/mlx5e: Set vlan masks for all offloaded TC rules

In flow steering, if asked to, the hardware matches on the first ethertype
which is not vlan. It's possible to set a rule as follows, which is meant
to match on untagged packet, but will match on a vlan packet:
    tc filter add dev eth0 parent ffff: protocol ip flower ...

To avoid this for packets with single tag, we set vlan masks to tell
hardware to check the tags for every matched packet.

Fixes: 9b592f84c009 ('net/mlx5e: Add TC vlan match parsing')
Signed-off-by: Jianbo Liu <jianbol@mellanox.com>
Reviewed-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c