summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorEli Britstein <elibr@mellanox.com>2020-06-28 14:42:26 +0200
committerSaeed Mahameed <saeedm@mellanox.com>2020-07-10 04:27:07 +0200
commiteb32b3f53d283e8d68b6d86c3a6ed859b24dacae (patch)
tree025d2584ba8e59209988e297959b38d6fb8010b6 /drivers
parentnet/mlx5e: Fix port buffers cell size value (diff)
downloadlinux-eb32b3f53d283e8d68b6d86c3a6ed859b24dacae.tar.xz
linux-eb32b3f53d283e8d68b6d86c3a6ed859b24dacae.zip
net/mlx5e: CT: Fix memory leak in cleanup
CT entries are deleted via a workqueue from netfilter. If removing the module before that, the rules are cleaned by the driver itself, but the memory entries for them are not freed. Fix that. Fixes: ac991b48d43c ("net/mlx5e: CT: Offload established flows") Signed-off-by: Eli Britstein <elibr@mellanox.com> Reviewed-by: Roi Dayan <roid@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c b/drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c
index 430025550fad..aad1c29b23db 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c
@@ -1097,6 +1097,7 @@ mlx5_tc_ct_flush_ft_entry(void *ptr, void *arg)
struct mlx5_ct_entry *entry = ptr;
mlx5_tc_ct_entry_del_rules(ct_priv, entry);
+ kfree(entry);
}
static void