]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
net/mlx5: Allow ft level ignore for nic rx tables
authorAriel Levkovich <lariel@mellanox.com>
Mon, 27 Apr 2020 22:39:38 +0000 (01:39 +0300)
committerSaeed Mahameed <saeedm@nvidia.com>
Wed, 23 Sep 2020 22:44:34 +0000 (15:44 -0700)
Allow setting a flow table with a lower level
as a rule destination in nic rx tables.
This is required in order to support table chaining
of tc nic flows.

Signed-off-by: Ariel Levkovich <lariel@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/fs_core.c

index 75fa44eee434d9538a3d82e78994dfb63cdece16..6141e9ec819035ecc90a2379a08b4ac0121eebb8 100644 (file)
@@ -1595,11 +1595,12 @@ static bool dest_is_valid(struct mlx5_flow_destination *dest,
                return true;
 
        if (ignore_level) {
-               if (ft->type != FS_FT_FDB)
+               if (ft->type != FS_FT_FDB &&
+                   ft->type != FS_FT_NIC_RX)
                        return false;
 
                if (dest->type == MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE &&
-                   dest->ft->type != FS_FT_FDB)
+                   ft->type != dest->ft->type)
                        return false;
        }