]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Fix matchall police parameters validation
authorVlad Buslov <vladbu@nvidia.com>
Mon, 4 Jul 2022 20:44:05 +0000 (22:44 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 6 Jul 2022 11:44:39 +0000 (12:44 +0100)
commit9ae296a0761dee2dea32afddeb659946e88403eb
tree01fa9fc940185a231a27369ef54ea437bff3d4d0
parent623385d613bcf24ec555ac8a5780354a09a69423
net/mlx5e: Fix matchall police parameters validation

Referenced commit prepared the code for upcoming extension that allows mlx5
to offload police action attached to flower classifier. However, with
regard to existing matchall classifier offload validation should be
reversed as FLOW_ACTION_CONTINUE is the only supported notexceed police
action type. Fix the problem by allowing FLOW_ACTION_CONTINUE for police
action and extend scan_tc_matchall_fdb_actions() to only allow such actions
with matchall classifier.

Fixes: cc33b6c8b6f5 ("flow_offload: reject offload for all drivers with invalid police parameters")
Signed-off-by: Vlad Buslov <vladbu@nvidia.com>
Acked-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c