Skip to content

net/ice: fix DCF memory leaks

Anurag Mandal dpdk-dev 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest8 patches 2 repliesIn review
  2. v18 patches 8 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8net/ice: fix DCF hardware init error pathdrivers/net/intel/ice/ice_dcf.c+10 -10 replies
2/8net/ice: fix DCF parent adapter init error pathdrivers/net/intel/ice/ice_dcf_parent.c+7 -20 replies
3/8net/ice: fix DCF queue config buffer leakdrivers/net/intel/ice/ice_dcf.c+2 -00 replies
4/8net/ice: fix DCF QoS buffer leak on commitdrivers/net/intel/ice/ice_dcf_sched.c+2 -00 replies
5/8net/ice: fix DCF QoS bandwidth replay config leakdrivers/net/intel/ice/ice_dcf.c drivers/net/intel/ice/ice_dcf_ethdev.h drivers/net/intel/ice/ice_dcf_parent.c +1 more+32 -81 reply
6/8net/ice: fix DCF TM config leak on closedrivers/net/intel/ice/ice_dcf.c+4 -40 replies
7/8net/ice: fix DCF representor info leak on closedrivers/net/intel/ice/ice_dcf_ethdev.c+15 -80 replies
8/8net/ice: fix DCF port leak on probe failuredrivers/net/intel/ice/ice_dcf_ethdev.c+20 -50 replies

Reviews trailers per patch

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

PatchBruce Richardson
1/8A-b
2/8A-b
3/8A-b
4/8A-b
5/8A-b
6/8A-b
7/8A-b
8/8A-b

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

Read the v2 thread

Cover letter [PATCH v2 0/8] net/ice: fix DCF memory leaks

V2-changes:
- Addressed Bruce Richardson's review comments.
- Patch-1: use rte_intr_callback_unregister_sync() in the new error path.
- Patch-5: fix the re-commit leak by swapping the saved config under the lock the VF reset replay holds.

This patch series fixes memory leaks, and related error path issues, in the ice DCF driver.

1. The VF VSI map leaked on DCF hardware init failure, and a failed VLAN capability query left the interrupt callback registered.

2. A failed DCF parent adapter init leaked the dummy main VSI, and a failed flow init also leaked the DDP parser and flow engine state.

3. The queue config message leaked when the required RXDID was not supported.

4. The temporary QoS bandwidth buffers still leaked on every successful hierarchy commit.

5. The QoS bandwidth config saved for replay leaked on every commit, close and reset.

6. TM nodes and shaper profiles leaked on close when the hierarchy was never committed.

7. The representor info leaked when the DCF port was closed.

8. A failed probe left the DCF port and its representors behind. A representor type other than VF is now rejected before the DCF port is created.

Anurag Mandal (8):
net/ice: fix DCF hardware init error path net/ice: fix DCF parent adapter init error path net/ice: fix DCF queue config buffer leak net/ice: fix DCF QoS buffer leak on commit net/ice: fix DCF QoS bandwidth replay config leak net/ice: fix DCF TM config leak on close net/ice: fix DCF representor info leak on close net/ice: fix DCF port leak on probe failure

 drivers/net/intel/ice/ice_dcf.c        | 27 ++++++++++++---
 drivers/net/intel/ice/ice_dcf_ethdev.c | 48 +++++++++++++++++++-------
 drivers/net/intel/ice/ice_dcf_ethdev.h |  2 ++
 drivers/net/intel/ice/ice_dcf_parent.c | 24 +++++++++++--
 drivers/net/intel/ice/ice_dcf_sched.c  | 19 +++++-----
 5 files changed, 92 insertions(+), 28 deletions(-)
Signature · 1 line
2.25.1