net/mlx5e: Remove limitation of single NIC offloaded TC action per rule
authorOr Gerlitz <ogerlitz@mellanox.com>
Tue, 28 Feb 2017 08:48:35 +0000 (10:48 +0200)
committerSaeed Mahameed <saeedm@mellanox.com>
Thu, 8 Jun 2017 11:11:59 +0000 (14:11 +0300)
Remove the limitation that offloaded NIC filters can have only one
action. This allows us for example to provide flow tag as a note
to upper layers / apps that that HW header re-write was applied.

Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Reviewed-by: Paul Blakey <paulb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c

index 8ec13f9be66014098332db1b76198f9fa3bd5508..cfb32fe5129dc9627b00e9d2eea9cce622c55c01 100644 (file)
@@ -1194,10 +1194,6 @@ static int parse_tc_nic_actions(struct mlx5e_priv *priv, struct tcf_exts *exts,
 
        tcf_exts_to_list(exts, &actions);
        list_for_each_entry(a, &actions, list) {
-               /* Only support a single action per rule */
-               if (attr->action)
-                       return -EINVAL;
-
                if (is_tcf_gact_shot(a)) {
                        attr->action |= MLX5_FLOW_CONTEXT_ACTION_DROP;
                        if (MLX5_CAP_FLOWTABLE(priv->mdev,