From: Kumar Kartikeya Dwivedi <memxor@gmail.com>
To: bpf@vger.kernel.org
Cc: Alexei Starovoitov <ast@kernel.org>,
Andrii Nakryiko <andrii@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Martin KaFai Lau <martin.lau@kernel.org>,
Eduard Zingerman <eddyz87@gmail.com>,
kkd@meta.com, kernel-team@meta.com
Subject: [PATCH bpf-next v1 0/2] Global subprogs in RCU/{preempt,irq}-disabled sections
Date: Fri, 28 Feb 2025 08:28:56 -0800 [thread overview]
Message-ID: <20250228162858.1073529-1-memxor@gmail.com> (raw)
Small change to allow non-sleepable global subprogs in
RCU, preempt-disabled, and irq-disabled sections. For
now, we don't lift the limitation for locks as it requires
more analysis, and will do this one resilient spin locks
land.
This surfaced a bug where sleepable global subprogs were
allowed in RCU read sections, that has been fixed. Tests
have been added to cover various cases.
Kumar Kartikeya Dwivedi (2):
bpf: Summarize sleepable global subprogs
selftests/bpf: Test sleepable global subprogs in atomic contexts
include/linux/bpf_verifier.h | 1 +
kernel/bpf/verifier.c | 50 ++++++++++-----
.../selftests/bpf/prog_tests/rcu_read_lock.c | 2 +
.../selftests/bpf/prog_tests/spin_lock.c | 2 +
tools/testing/selftests/bpf/progs/irq.c | 62 ++++++++++++++++++-
.../selftests/bpf/progs/preempt_lock.c | 40 +++++++++++-
.../selftests/bpf/progs/rcu_read_lock.c | 38 ++++++++++++
.../selftests/bpf/progs/test_spin_lock_fail.c | 40 ++++++++++++
8 files changed, 219 insertions(+), 16 deletions(-)
base-commit: 0b9363131daf4227d5ae11ee677acdcfff06e938
--
2.43.5
next reply other threads:[~2025-02-28 16:29 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-28 16:28 Kumar Kartikeya Dwivedi [this message]
2025-02-28 16:28 ` [PATCH bpf-next v1 1/2] bpf: Summarize sleepable global subprogs Kumar Kartikeya Dwivedi
2025-02-28 20:42 ` Eduard Zingerman
2025-02-28 20:47 ` Kumar Kartikeya Dwivedi
2025-02-28 23:18 ` Andrii Nakryiko
2025-02-28 23:23 ` Eduard Zingerman
2025-02-28 23:34 ` Andrii Nakryiko
2025-02-28 23:57 ` Eduard Zingerman
2025-03-01 1:43 ` Kumar Kartikeya Dwivedi
2025-02-28 16:28 ` [PATCH bpf-next v1 2/2] selftests/bpf: Test sleepable global subprogs in atomic contexts Kumar Kartikeya Dwivedi
2025-02-28 21:21 ` Eduard Zingerman
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=20250228162858.1073529-1-memxor@gmail.com \
--to=memxor@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=eddyz87@gmail.com \
--cc=kernel-team@meta.com \
--cc=kkd@meta.com \
--cc=martin.lau@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