]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum: Use dedicated trap group for ACL trap
authorIdo Schimmel <idosch@mellanox.com>
Mon, 25 May 2020 23:05:43 +0000 (02:05 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 27 May 2020 03:33:57 +0000 (20:33 -0700)
commit14b8d854b1a38eacc9056166b2af44280c417c83
tree04905d40556779435c749c7bab0215aaffbd9a05
parent5fe7c9d9c61dc611a250eb1e230c353798d07371
mlxsw: spectrum: Use dedicated trap group for ACL trap

Packets that are trapped via tc's trap action are currently subject to
the same policer as packets hitting local routes. The latter are
critical to the correct functioning of the control plane, while the
former are mainly used for traffic inspection.

Split the ACL trap to a separate group with its own policer. Use a
higher priority for these traps than for traps using mirror action
(e.g., ARP, IGMP). Otherwise, packets matching both traps will not be
forwarded in hardware (because of trap action) and also not forwarded in
software because they will be marked with 'offload_fwd_mark'.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/reg.h
drivers/net/ethernet/mellanox/mlxsw/spectrum.c