Commit 6fb0701a authored by Paul Blakey's avatar Paul Blakey Committed by David S. Miller
Browse files

net/mlx5: E-Switch, Add support for offloading rules with no in_port



FTEs in global tables may match on packets from multiple in_ports.
Provide the capability to omit the in_port match condition.

Signed-off-by: default avatarPaul Blakey <paulb@mellanox.com>
Reviewed-by: default avatarOz Shlomo <ozsh@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent d18296ff
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -391,6 +391,7 @@ enum {
enum {
	MLX5_ESW_ATTR_FLAG_VLAN_HANDLED  = BIT(0),
	MLX5_ESW_ATTR_FLAG_SLOW_PATH     = BIT(1),
	MLX5_ESW_ATTR_FLAG_NO_IN_PORT    = BIT(2),
};

struct mlx5_esw_flow_attr {
+3 −1
Original line number Diff line number Diff line
@@ -388,6 +388,8 @@ mlx5_eswitch_add_offloaded_rule(struct mlx5_eswitch *esw,
							attr->prio, 0);
		else
			fdb = attr->fdb;

		if (!(attr->flags & MLX5_ESW_ATTR_FLAG_NO_IN_PORT))
			mlx5_eswitch_set_rule_source_port(esw, spec, attr);
	}
	if (IS_ERR(fdb)) {