[PATCH 6/7] s390/word-at-a-time: Instrument load_unaligned_zeropad()

From: Bill Wendling

Date: Fri Sep 11 2026 - 03:06:24 EST


Convert s390 to the arch_load_unaligned_zeropad() /
load_unaligned_zeropad() split introduced for x86 earlier in this
series, so KASAN/KCSAN also see reads through load_unaligned_zeropad()
on this architecture.

Assisted-by: Claude:claude-sonnet-5
Signed-off-by: Bill Wendling <morbo@xxxxxxxxxx>
---
Cc: Heiko Carstens <hca@xxxxxxxxxxxxx>
Cc: Vasily Gorbik <gor@xxxxxxxxxxxxx>
Cc: Alexander Gordeev <agordeev@xxxxxxxxxxxxx>
Cc: Christian Borntraeger <borntraeger@xxxxxxxxxxxxx>
Cc: Sven Schnelle <svens@xxxxxxxxxxxxx>
Cc: linux-s390@xxxxxxxxxxxxxxx
Cc: linux-kernel@xxxxxxxxxxxxxxx
---
arch/s390/include/asm/word-at-a-time.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/s390/include/asm/word-at-a-time.h b/arch/s390/include/asm/word-at-a-time.h
index eaa19dee7699..6a055bee5ba0 100644
--- a/arch/s390/include/asm/word-at-a-time.h
+++ b/arch/s390/include/asm/word-at-a-time.h
@@ -48,7 +48,7 @@ static inline unsigned long zero_bytemask(unsigned long data)
* and the next page not being mapped, take the exception and
* return zeroes in the non-existing part.
*/
-static inline unsigned long load_unaligned_zeropad(const void *addr)
+static inline unsigned long arch_load_unaligned_zeropad(const void *addr)
{
unsigned long data;

@@ -62,4 +62,6 @@ static inline unsigned long load_unaligned_zeropad(const void *addr)
return data;
}

+#include <asm-generic/word-at-a-time-instrumented.h>
+
#endif /* _ASM_WORD_AT_A_TIME_H */
--
2.47.3