Files
linux/drivers
Dinghao Liu 1750f55d85 net/mlx5e: fix a potential double-free in fs_udp_create_groups
[ Upstream commit e75efc6466ae289e599fb12a5a86545dff245c65 ]

When kcalloc() for ft->g succeeds but kvzalloc() for in fails,
fs_udp_create_groups() will free ft->g. However, its caller
fs_udp_create_table() will free ft->g again through calling
mlx5e_destroy_flow_table(), which will lead to a double-free.
Fix this by setting ft->g to NULL in fs_udp_create_groups().

Fixes: 1c80bd6843 ("net/mlx5e: Introduce Flow Steering UDP API")
Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-01-01 12:38:55 +00:00
..
2023-09-13 09:42:56 +02:00
2023-11-20 11:52:05 +01:00
2023-12-20 17:00:20 +01:00
2023-09-13 09:42:58 +02:00
2023-12-08 08:51:19 +01:00
2023-12-13 18:39:03 +01:00
2023-07-19 16:21:48 +02:00