]> git.ipfire.org Git - thirdparty/linux.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)
commit4d1e07d83ccc87f210e5b852b0a5ea812a2f191c
tree01fa9fc940185a231a27369ef54ea437bff3d4d0
parent052f744f44462cc49b88a125b0f7b93a9e47a9dd
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: d97b4b105ce7 ("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