From: sashiko-bot@kernel.org
To: "Heiko Carstens" <hca@linux.ibm.com>
Cc: linux-s390@vger.kernel.org, "Vasily Gorbik" <gor@linux.ibm.com>,
"Alexander Gordeev" <agordeev@linux.ibm.com>,
"Christian Borntraeger" <borntraeger@linux.ibm.com>
Subject: Re: [PATCH v2 10/10] s390/maccess: Remove spinlock from __s390_kernel_write()
Date: Tue, 27 Oct 2026 14:41:22 +0000 [thread overview]
Message-ID: <sashiko-outbox-186747@kernel.org> (raw)
In-Reply-To: <20261027143030.3154657-11-hca@linux.ibm.com>
> The spinlock in __s390_kernel_write() was introduced to serialize the
> read-modify-write sequence against concurrent callers. Now that all
> runtime callers of s390_kernel_write() hold the text_mutex, the
> spinlock is not required anymore.
>
> Replace it with preempt_disable() / preempt_enable() and sync_core().
> Previously, CPU serialization was implicitly done by other
> instructions. Make this explicit with sync_core() instead of
> relying on that.
>
> Preemption is disabled so that sync_core() issues the CPU serialization
> instruction on the same CPU that executed the stores. This completes all
> previous stores and makes them visible to other CPUs.
>
> Other CPUs need to perform CPU serialization, e.g. with text_poke_sync(),
> [ ... ]
> Work around that by calling the non-checking __s390_kernel_write(),
> and add lockdep_assert_held() checks to arch_arm_kprobe() and
> arch_disarm_kprobe().
>
> Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261027143030.3154657-1-hca@linux.ibm.com?part=10
next prev parent reply other threads:[~2026-10-27 14:41 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-27 14:30 [PATCH v2 00/10] s390: Consistent usage of text_mutex Heiko Carstens
2026-10-27 14:30 ` [PATCH v2 01/10] s390/jump_label: Serialize text patching with text_mutex Heiko Carstens
2026-10-27 14:35 ` sashiko-bot
2026-10-28 10:50 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 02/10] s390/ftrace: " Heiko Carstens
2026-10-27 14:37 ` sashiko-bot
2026-10-28 10:54 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 03/10] s390/bpf: " Heiko Carstens
2026-10-27 14:35 ` sashiko-bot
2026-10-28 10:56 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 04/10] s390/runtime-const: " Heiko Carstens
2026-10-27 14:34 ` sashiko-bot
2026-10-28 10:58 ` Ilya Leoshkevich
2026-10-28 11:09 ` Heiko Carstens
2026-10-28 12:22 ` Ilya Leoshkevich
2026-10-28 13:43 ` Heiko Carstens
2026-10-27 14:30 ` [PATCH v2 05/10] s390/module: " Heiko Carstens
2026-10-27 14:36 ` sashiko-bot
2026-10-28 10:59 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 06/10] s390/stackprotector: " Heiko Carstens
2026-10-27 14:34 ` sashiko-bot
2026-10-28 12:23 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 07/10] s390/nospec-branch: " Heiko Carstens
2026-10-27 14:35 ` sashiko-bot
2026-10-28 12:24 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 08/10] s390/alternative: " Heiko Carstens
2026-10-27 14:36 ` sashiko-bot
2026-10-28 12:25 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 09/10] s390/uaccess: Move s390_kernel_write() to asm/text-patching.h Heiko Carstens
2026-10-27 14:35 ` sashiko-bot
2026-10-28 12:26 ` Ilya Leoshkevich
2026-10-27 14:30 ` [PATCH v2 10/10] s390/maccess: Remove spinlock from __s390_kernel_write() Heiko Carstens
2026-10-27 14:41 ` sashiko-bot [this message]
2026-10-28 20:59 ` Ilya Leoshkevich
2026-10-29 10:57 ` Heiko Carstens
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=sashiko-outbox-186747@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=agordeev@linux.ibm.com \
--cc=borntraeger@linux.ibm.com \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=linux-s390@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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