[PATCH 0/4] s390: Consistent usage of text_mutex
From: Heiko Carstens
Date: Mon Oct 26 2026 - 08:34:09 EST
Other architectures serialize kernel text patching with text_mutex. s390
does not: __s390_kernel_write() relies on a private spinlock, and callers
partially depend on implicit exclusion (e.g. no kprobe can be set on a
jump label).
Make s390 consistent with other architectures:
- Patches 1-3 add text_mutex to the jump_label, ftrace and bpf text
patching paths
- Patch 4 removes the redundant spinlock from __s390_kernel_write().
CPU serialization, previously done implicitly, is now explicit via
sync_core()
Thanks,
Heiko
Heiko Carstens (4):
s390/jump_label: Serialize text patching with text_mutex
s390/ftrace: Serialize text patching with text_mutex
s390/bpf: Serialize text patching with text_mutex
s390/maccess: Remove spinlock from __s390_kernel_write()
arch/s390/kernel/ftrace.c | 9 +++++++++
arch/s390/kernel/jump_label.c | 3 +++
arch/s390/mm/maccess.c | 9 ++++-----
arch/s390/net/bpf_jit_comp.c | 21 +++++++++++++++++----
4 files changed, 33 insertions(+), 9 deletions(-)
--
2.53.0