]> www.infradead.org Git - users/jedix/linux-maple.git/commit
net/mlx5e: TC, Offload rewrite and mirror to both internal and external dests
authorJianbo Liu <jianbol@nvidia.com>
Thu, 8 Aug 2024 05:59:20 +0000 (08:59 +0300)
committerJakub Kicinski <kuba@kernel.org>
Sat, 10 Aug 2024 05:13:14 +0000 (22:13 -0700)
commitb11bde56246ee85a67364efa0e181b479543dfef
tree5f84d162e69452111e61b67f53117a48524047f1
parent16bb8c613379e20d4adabc639ea6aecdaeba2ff1
net/mlx5e: TC, Offload rewrite and mirror to both internal and external dests

Firmware has the limitation that it cannot offload a rule with rewrite
and mirror to internal and external destinations simultaneously.

This patch adds a workaround to this issue. Here the destination array
is split again, just like what's done in previous commit, but after
the action indexed by split_count - 1. An extra rule is added for the
leftover destinations. Such rule can be offloaded, even there are
destinations to both internal and external destinations, because the
header rewrite is left in the original FTE.

Signed-off-by: Jianbo Liu <jianbol@nvidia.com>
Reviewed-by: Cosmin Ratiu <cratiu@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/20240808055927.2059700-5-tariqt@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c