From: Song Liu <song@kernel.org>
To: <linux-mm@kvack.org>, <bpf@vger.kernel.org>, <netdev@vger.kernel.org>
Cc: <ast@kernel.org>, <daniel@iogearbox.net>, <andrii@kernel.org>,
<kernel-team@fb.com>, <akpm@linux-foundation.org>,
<eric.dumazet@gmail.com>, Song Liu <song@kernel.org>
Subject: [PATCH bpf-next 0/2] flexible size for bpf_prog_pack
Date: Wed, 9 Feb 2022 22:41:06 -0800 [thread overview]
Message-ID: <20220210064108.1095847-1-song@kernel.org> (raw)
There are two issues with bpf_prog_pack:
(1) On NUMA systems, bpf_prog_pack need to be bigger
(PMD_SIZE * num_online_nodes) to use huge pages.
(2) If the system doesn't support huge pages (nohugevmalloc in cmdline),
allocating PMD_SIZE for bpf_prog_pack is a waste.
Address these issues with flexible bpf_prog_pack_size().
Song Liu (2):
vmalloc: expose vmap_allow_huge via get_vmap_allow_huge()
bpf: flexible size for bpf_prog_pack
include/linux/vmalloc.h | 1 +
kernel/bpf/core.c | 47 +++++++++++++++++++++++------------------
mm/vmalloc.c | 5 +++++
3 files changed, 33 insertions(+), 20 deletions(-)
--
2.30.2
next reply other threads:[~2022-02-10 6:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-10 6:41 Song Liu [this message]
2022-02-10 6:41 ` [PATCH bpf-next 1/2] vmalloc: expose vmap_allow_huge via get_vmap_allow_huge() Song Liu
2022-02-10 6:41 ` [PATCH bpf-next 2/2] bpf: flexible size for bpf_prog_pack Song Liu
[not found] ` <34d0ed40-30cf-a1a2-f4eb-fa3d0a55bce8@iogearbox.net>
2022-02-10 16:51 ` Song Liu
[not found] ` <dd6dee71-94d7-5393-8fe6-c667938ebfac@iogearbox.net>
2022-02-11 19:42 ` Song Liu
2022-03-01 23:01 ` Song Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220210064108.1095847-1-song@kernel.org \
--to=song@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=eric.dumazet@gmail.com \
--cc=kernel-team@fb.com \
--cc=linux-mm@kvack.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).