Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

net/mlx5: E-Switch, Use same source for offloaded actions check

Align the checks for modify header and encap actions with the
rest of the code.

Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>

authored by

Or Gerlitz and committed by
Saeed Mahameed
aa24670e 7cbaf9a3

+2 -2
+2 -2
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
··· 88 88 if (flow_act.action & MLX5_FLOW_CONTEXT_ACTION_DECAP) 89 89 spec->match_criteria_enable |= MLX5_MATCH_INNER_HEADERS; 90 90 91 - if (attr->action & MLX5_FLOW_CONTEXT_ACTION_MOD_HDR) 91 + if (flow_act.action & MLX5_FLOW_CONTEXT_ACTION_MOD_HDR) 92 92 flow_act.modify_id = attr->mod_hdr_id; 93 93 94 - if (attr->action & MLX5_FLOW_CONTEXT_ACTION_ENCAP) 94 + if (flow_act.action & MLX5_FLOW_CONTEXT_ACTION_ENCAP) 95 95 flow_act.encap_id = attr->encap_id; 96 96 97 97 rule = mlx5_add_flow_rules((struct mlx5_flow_table *)esw->fdb_table.fdb,