Skip to content

Commit bdf788c

Browse files
Jianbo Liukuba-moo
authored andcommitted
net/mlx5e: Don't modify the peer sent-to-vport rules for IPSec offload
As IPSec packet offload in switchdev mode is not supported with LAG, it's unnecessary to modify those sent-to-vport rules to the peer eswitch. Fixes: c6c2bf5 ("net/mlx5e: Support IPsec packet offload for TX in switchdev mode") Signed-off-by: Jianbo Liu <[email protected]> Reviewed-by: Leon Romanovsky <[email protected]> Reviewed-by: Roi Dayan <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 0c101a2 commit bdf788c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -984,7 +984,8 @@ mlx5_eswitch_add_send_to_vport_rule(struct mlx5_eswitch *on_esw,
984984
dest.vport.flags |= MLX5_FLOW_DEST_VPORT_VHCA_ID;
985985
flow_act.action = MLX5_FLOW_CONTEXT_ACTION_FWD_DEST;
986986

987-
if (rep->vport == MLX5_VPORT_UPLINK && on_esw->offloads.ft_ipsec_tx_pol) {
987+
if (rep->vport == MLX5_VPORT_UPLINK &&
988+
on_esw == from_esw && on_esw->offloads.ft_ipsec_tx_pol) {
988989
dest.ft = on_esw->offloads.ft_ipsec_tx_pol;
989990
flow_act.flags = FLOW_ACT_IGNORE_FLOW_LEVEL;
990991
dest.type = MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE;

0 commit comments

Comments
 (0)