Skip to content

cleanup more resources on eal_cleanup

Stephen Hemminger dpdk-dev 3 versions Applied

Status from this message: Applied, thanks.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest5 patches 1 replyApplied
  2. v55 patches 0 repliesSuperseded
  3. v45 patches 0 repliesSuperseded

Patches in v6 Applied

#Subject and filesSizeRepliesApplied
1/5eal: close log in eal_cleanuplib/eal/common/eal_common_log.c lib/eal/common/eal_private.h lib/eal/linux/eal.c +1 more+29 -00 replies
2/5eal: mp: end the multiprocess thread during cleanuplib/eal/common/eal_common_proc.c+17 -30 replies
3/5eal: vfio: cleanup the mp sync handlelib/eal/linux/eal.c lib/eal/linux/eal_vfio.h lib/eal/linux/eal_vfio_mp_sync.c+13 -00 replies
4/5eal: hotplug: cleanup multiprocess resourceslib/eal/common/hotplug_mp.c lib/eal/common/hotplug_mp.h lib/eal/linux/eal.c+12 -00 replies
5/5eal: malloc: cleanup mp resourceslib/eal/common/malloc_heap.c lib/eal/common/malloc_heap.h lib/eal/common/malloc_mp.c +3 more+32 -00 replies

Reviews trailers per patch

3 of 5 patches have a Reviewed-by or Acked-by.

PatchAnatoly Burakov
1/5
2/5A-b
3/5A-b
4/5
5/5A-b

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

Read the v6 thread

Cover letter [PATCH v6 0/5] cleanup more resources on eal_cleanup

When testing using ASAN or valgrind with DPDK; there are lots of leftover memory and file descriptors. This makes it hard to find application leaks versus internal DPDK leaks.

The DPDK has a function that applications can use to tell it to cleanup resources on shutdown (rte_eal_cleanup). But the current coverage of that API is spotty. Many internal parts of DPDK leave files and allocated memory behind.

This patch set is a first step at getting the sub-parts of DPDK to cleanup after themselves. These are the easier ones, the harder and more critical ones are in the drivers and the memory subsystem.

There should be no new exposed API or ABI changes here.

v6 - fix windows stub
v5 - add stub for windows build in rte_malloc cleanup v4
- rebase to 20.11-rc
- drop one patch (alarm cleanup is implemented)
- drop patch that ends worker threads on cleanup.
the test is calling rte_exit/eal_cleanup in a forked process. (could argue this is a test bug)!

Stephen Hemminger (5):
eal: close log in eal_cleanup
eal: mp: end the multiprocess thread during cleanup
eal: vfio: cleanup the mp sync handle
eal: hotplug: cleanup multiprocess resources
eal: malloc: cleanup mp resources

 lib/eal/common/eal_common_log.c  | 13 +++++++++++++
 lib/eal/common/eal_common_proc.c | 20 +++++++++++++++++---
 lib/eal/common/eal_private.h     |  7 +++++++
 lib/eal/common/hotplug_mp.c      |  5 +++++
 lib/eal/common/hotplug_mp.h      |  6 ++++++
 lib/eal/common/malloc_heap.c     |  6 ++++++
 lib/eal/common/malloc_heap.h     |  3 +++
 lib/eal/common/malloc_mp.c       | 12 ++++++++++++
 lib/eal/common/malloc_mp.h       |  3 +++
 lib/eal/linux/eal.c              |  7 +++++++
 lib/eal/linux/eal_log.c          |  8 ++++++++
 lib/eal/linux/eal_vfio.h         |  1 +
 lib/eal/linux/eal_vfio_mp_sync.c |  8 ++++++++
 lib/eal/windows/eal_mp.c         |  7 +++++++
 14 files changed, 103 insertions(+), 3 deletions(-)
Signature · 1 line
2.30.2