diff options
author | Eli Cohen <eli@mellanox.com> | 2020-03-04 10:32:56 +0200 |
---|---|---|
committer | Saeed Mahameed <saeedm@mellanox.com> | 2020-03-25 23:19:06 -0700 |
commit | 454401aeb2957e0d996bc9208b78aa4d8ac12964 (patch) | |
tree | dda7c057647a4ff3a1e5f80819515ad298d5f2ef /drivers | |
parent | b820ce00e03af3255e1db9cc086caf742ea32809 (diff) |
net/mlx5: Fix group version management
When adding a rule to a flow group we need increment the version of the
group. Current code fails to do that and as a result, when trying to add
a rule, we will fail to discover a case where an FTE with the same match
value was added while we scanned the groups of the same match criteria,
thus we may try to add an FTE that was already added.
Signed-off-by: Eli Cohen <eli@mellanox.com>
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c b/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c index a9ec40ca7893..751dd5869485 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c @@ -1323,6 +1323,7 @@ add_rule_fte(struct fs_fte *fte, fte->node.active = true; fte->status |= FS_FTE_STATUS_EXISTING; atomic_inc(&fte->node.version); + atomic_inc(&fg->node.version); out: return handle; |