public inbox for bpf@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] bpf/s390: Implement get_preempt_count()
@ 2026-02-17 16:05 Ilya Leoshkevich
  2026-02-17 16:05 ` [PATCH 1/2] s390: Introduce bpf_get_lowcore() kfunc Ilya Leoshkevich
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Ilya Leoshkevich @ 2026-02-17 16:05 UTC (permalink / raw)
  To: Alexei Starovoitov, Daniel Borkmann, Andrii Nakryiko
  Cc: bpf, Heiko Carstens, Vasily Gorbik, Alexander Gordeev,
	Ilya Leoshkevich

Hi,

This series adds get_preempt_count() BPF implementation for s390.
On s390 preempt_count lives in lowcore: a per-cpu data structure
mapped at virtual address 0 or 0x70000 depending on the kernel
command line.

Patch 1 adds a kfunc to obtain lowcore address.
Patch 2 is the implementation that delegates to it.

Best regards,
Ilya

Ilya Leoshkevich (2):
  s390: Introduce bpf_get_lowcore() kfunc
  bpf/s390: Implement get_preempt_count()

 arch/s390/kernel/Makefile                      |  2 ++
 arch/s390/kernel/bpf.c                         | 12 ++++++++++++
 kernel/bpf/helpers.c                           |  3 +++
 tools/testing/selftests/bpf/bpf_experimental.h | 11 +++++++++++
 4 files changed, 28 insertions(+)
 create mode 100644 arch/s390/kernel/bpf.c

-- 
2.53.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2026-03-03 16:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-17 16:05 [PATCH 0/2] bpf/s390: Implement get_preempt_count() Ilya Leoshkevich
2026-02-17 16:05 ` [PATCH 1/2] s390: Introduce bpf_get_lowcore() kfunc Ilya Leoshkevich
2026-02-17 16:05 ` [PATCH 2/2] bpf/s390: Implement get_preempt_count() Ilya Leoshkevich
2026-02-17 17:55 ` [PATCH 0/2] " Vasily Gorbik
2026-02-17 19:32   ` Alexei Starovoitov
2026-02-17 23:34     ` Ilya Leoshkevich
2026-02-18  0:18       ` Alexei Starovoitov
2026-03-03 16:40 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox