Skip to content

net/mlx5: Fix NULL dereference and memory leak in ttc_table creation

Henry Martin linux-rdma lkml netdev 7 versions – Applied

Status from this message: This series was applied to netdev/net.git (main)

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v7 Latest2 patches 2 repliesApplied 2/2
  2. v62 patches 6 repliesSuperseded
  3. v52 patches 4 repliesSuperseded
Earlier versions · 4
VersionPostedPatchesRepliesStatus
v41 patch4 repliesSuperseded
v31 patch2 repliesSuperseded
v22 patches1 replySuperseded
v11 patch0 repliesSuperseded

Patches in v7 All 2 applied

#Subject and filesSizeRepliesApplied
1/2net/mlx5: Fix null-ptr-deref in mlx5_create_{inner_,}ttc_table()drivers/net/ethernet/mellanox/mlx5/core/lib/fs_ttc.c+10 -01 replyApplied
2/2net/mlx5: Move ttc allocation after switch case to prevent leaksdrivers/net/ethernet/mellanox/mlx5/core/lib/fs_ttc.c+8 -80 repliesApplied

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchMark BlochMichal Swiatkowski
1/2R-b R-b
2/2R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v7 thread

Cover letter [PATCH v7 0/2] net/mlx5: Fix NULL dereference and memory leak in ttc_table creation

This patch series addresses two issues in the mlx5_create_inner_ttc_table() and mlx5_create_ttc_table() functions:

1. A potential NULL pointer dereference if mlx5_get_flow_namespace() returns NULL.

2. A memory leak in the error path when ttc_type is invalid (default:
switch case).

Henry Martin (2):
net/mlx5: Fix null-ptr-deref in mlx5_create_{inner_,}ttc_table() net/mlx5: Move ttc allocation after switch case to prevent leaks

 .../ethernet/mellanox/mlx5/core/lib/fs_ttc.c  | 26 +++++++++++++------
 1 file changed, 18 insertions(+), 8 deletions(-)
Signature · 1 line
2.34.1