Skip to content

introduce HAVE_ARCH_HUGE_VMALLOC_FLAG for bpf_prog_pack

Song Liu bpf linux-mm netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 18 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4x86: disable HAVE_ARCH_HUGE_VMALLOCarch/x86/Kconfig+0 -11 reply
2/4vmalloc: introduce HAVE_ARCH_HUGE_VMALLOC_FLAGarch/Kconfig include/linux/vmalloc.h mm/vmalloc.c+35 -112 replies
3/4x86: select HAVE_ARCH_HUGE_VMALLOC_FLAG for X86_64arch/x86/Kconfig+1 -02 replies
4/4bpf: use __vmalloc_node_range() with VM_TRY_HUGE_VMAP for bpf_prog_packkernel/bpf/core.c+18 -32 replies

Reviews trailers per patch

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

Read the v1 thread

Cover letter [PATCH bpf 0/4] introduce HAVE_ARCH_HUGE_VMALLOC_FLAG for bpf_prog_pack

We prematurely enabled HAVE_ARCH_HUGE_VMALLOC for x86_64, which could cause issues [1], [2]. Fix this by with HAVE_ARCH_HUGE_VMALLOC_FLAG, which allows user of __vmalloc_node_range to ask for huge pages with a new flag VM_TRY_HUGE_VMAP. bpf_prog_pack is updated to use this __vmalloc_node_range with VM_TRY_HUGE_VMAP.

[1] https://lore.kernel.org/lkml/[email protected]/
[2] https://lore.kernel.org/netdev/[email protected]/

Song Liu (4):
x86: disable HAVE_ARCH_HUGE_VMALLOC
vmalloc: introduce HAVE_ARCH_HUGE_VMALLOC_FLAG
x86: select HAVE_ARCH_HUGE_VMALLOC_FLAG for X86_64
bpf: use __vmalloc_node_range() with VM_TRY_HUGE_VMAP for
bpf_prog_pack

 arch/Kconfig            |  9 +++++++++
 arch/x86/Kconfig        |  2 +-
 include/linux/vmalloc.h |  9 +++++++--
 kernel/bpf/core.c       | 21 ++++++++++++++++++---
 mm/vmalloc.c            | 28 +++++++++++++++++++---------
 5 files changed, 54 insertions(+), 15 deletions(-)

--
2.30.2