Skip to content

RFC Support running DPDK without hugetlbfs mountpoint

Anatoly Burakov dpdk-dev 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest10 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/10eal: add --no-shared-files optionlib/librte_eal/common/eal_common_options.c lib/librte_eal/common/eal_internal_cfg.h lib/librte_eal/common/eal_options.h+10 -00 replies
2/10eal: make --no-shconf an alias for --no-shared-fileslib/librte_eal/bsdapp/eal/eal.c lib/librte_eal/common/eal_common_memory.c lib/librte_eal/common/eal_common_options.c +4 more+19 -230 replies
3/10eal: make --huge-unlink an alias for --no-shared-fileslib/librte_eal/common/eal_common_options.c lib/librte_eal/common/eal_internal_cfg.h lib/librte_eal/common/eal_options.h +1 more+5 -170 replies
4/10fbarray: support no-shared-files modelib/librte_eal/common/eal_common_fbarray.c+42 -290 replies
5/10mem: add support for no-shared-files modelib/librte_eal/linuxapp/eal/eal.c lib/librte_eal/linuxapp/eal/eal_memalloc.c+29 -30 replies
6/10ipc: add support for no-shared-files modelib/librte_eal/common/eal_common_proc.c+25 -00 replies
7/10eal: add support for no-shared-files for hugepage infolib/librte_eal/bsdapp/eal/eal_hugepage_info.c lib/librte_eal/linuxapp/eal/eal_hugepage_info.c+8 -00 replies
8/10eal: add support for no-shared-files in hugepage data filelib/librte_eal/linuxapp/eal/eal_memory.c+12 -10 replies
9/10eal: do not create runtime dir in no-shared-files modelib/librte_eal/bsdapp/eal/eal.c lib/librte_eal/linuxapp/eal/eal.c+4 -20 replies
10/10mem: enable memfd-based hugepage allocationlib/librte_eal/linuxapp/eal/eal_hugepage_info.c lib/librte_eal/linuxapp/eal/eal_memalloc.c lib/librte_eal/linuxapp/eal/eal_memfd.h +1 more+234 -390 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC 00/10] Support running DPDK without hugetlbfs mountpoint

This patchset takes old debug options "--huge-unlink" and "--no-shconf" and replaces them both with a new option, "--no-shared-files". This is a special mode which will disable support for secondary processes, but which will cause DPDK to not create any shared files while running - neither hugepages nor any runtime data (everything will be entirely in memory).

Additionally, on supported kernel/glibc versions (Linux 4.14+, glibc 2.27+), "--no-shared-files" mode will also reserve hugepages using memfd instead of relying on hugetlbfs mountpoint. This will make it possible to use DPDK without hugetlbfs mountpoints (e.g. container use cases).

This changes functionality of several command-line switches, so RFC for now. Maybe we could leave the old switches as they are and deprecate them in the next release?

Anatoly Burakov (10):
eal: add --no-shared-files option
eal: make --no-shconf an alias for --no-shared-files
eal: make --huge-unlink an alias for --no-shared-files
fbarray: support no-shared-files mode
mem: add support for no-shared-files mode
ipc: add support for no-shared-files mode
eal: add support for no-shared-files for hugepage info
eal: add support for no-shared-files in hugepage data file
eal: do not create runtime dir in no-shared-files mode
mem: enable memfd-based hugepage allocation

 lib/librte_eal/bsdapp/eal/eal.c               |   7 +-
 lib/librte_eal/bsdapp/eal/eal_hugepage_info.c |   4 +
 lib/librte_eal/common/eal_common_fbarray.c    |  71 +++++----
 lib/librte_eal/common/eal_common_memory.c     |   3 +-
 lib/librte_eal/common/eal_common_options.c    |  25 ++--
 lib/librte_eal/common/eal_common_proc.c       |  25 ++++
 lib/librte_eal/common/eal_internal_cfg.h      |   3 +-
 lib/librte_eal/common/eal_options.h           |   7 +-
 lib/librte_eal/linuxapp/eal/eal.c             |  18 ++-
 .../linuxapp/eal/eal_hugepage_info.c          | 140 ++++++++++++++----
 lib/librte_eal/linuxapp/eal/eal_memalloc.c    | 126 +++++++++++++++-
 lib/librte_eal/linuxapp/eal/eal_memfd.h       |  28 ++++
 lib/librte_eal/linuxapp/eal/eal_memory.c      |  19 ++-
 test/test/test_eal_flags.c                    |  18 +--
 14 files changed, 384 insertions(+), 110 deletions(-)
 create mode 100644 lib/librte_eal/linuxapp/eal/eal_memfd.h
Signature · 1 line
2.17.0