From: Greg KH <greg@kroah.com>
To: Sasha Levin <sashal@kernel.org>
Cc: stable@vger.kernel.org, Thomas Huth <thuth@redhat.com>,
Heiko Carstens <hca@linux.ibm.com>,
Alexander Gordeev <agordeev@linux.ibm.com>
Subject: Re: [PATCH 6.12.y 1/2] s390: Replace __ASSEMBLY__ with __ASSEMBLER__ in non-uapi headers
Date: Wed, 30 Sep 2026 15:45:00 +0200 [thread overview]
Message-ID: <2026093056-clever-lustiness-56a5@gregkh> (raw)
In-Reply-To: <20260911112209.352376-1-sashal@kernel.org>
On Fri, Sep 11, 2026 at 07:22:08AM -0400, Sasha Levin wrote:
> From: Thomas Huth <thuth@redhat.com>
>
> [ Upstream commit 42398caf16c955251a2dab86f797b76adeb99899 ]
>
> While the GCC and Clang compilers already define __ASSEMBLER__
> automatically when compiling assembler code, __ASSEMBLY__ is a
> macro that only gets defined by the Makefiles in the kernel.
> This is bad since macros starting with two underscores are names
> that are reserved by the C language. It can also be very confusing
> for the developers when switching between userspace and kernelspace
> coding, or when dealing with uapi headers that rather should use
> __ASSEMBLER__ instead. So let's now standardize on the __ASSEMBLER__
> macro that is provided by the compilers.
>
> This is a completely mechanical patch (done with a simple "sed -i"
> statement), with some manual fixups done later while rebasing the
> patch.
>
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> Acked-by: Heiko Carstens <hca@linux.ibm.com>
> Link: https://lore.kernel.org/r/20250611140046.137739-3-thuth@redhat.com
> Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
>
> Backport notes for Linux 6.12:
> Keep the assembly-guard conversion only in asm/nmi.h, whose guard is
> context for 546dde823a36 ("KVM: s390: Fix memory corruption by not
> reinjecting CK machine checks"). Drop the other header conversions,
> including changes to machine.h and net/bpf_jit.h, which do not exist in
> this stable tree. Preserve all stable-specific header contents.
>
> Also include the one-line irq zero initialization from b239410c7653
> ("KVM: s390: Zero initialize irq in reinject_machine_check"). The target
> expects this initializer in its interrupt.c context; it also ensures
> that reinjected machine checks have zeroed padding and logout data.
> No functions are added. The target's machine-check fix is left for the
> separate target backport.
>
> [ sashal: Reduced backport -- upstream 42398caf16c95 touches 33 file(s), this
> backport carries 2. Not backported here:
> arch/s390/boot/boot.h
> arch/s390/include/asm/alternative.h
> arch/s390/include/asm/asm-const.h
> arch/s390/include/asm/cpu.h
> arch/s390/include/asm/cpu_mf-insn.h
> arch/s390/include/asm/ctlreg.h
> arch/s390/include/asm/dwarf.h
> arch/s390/include/asm/extmem.h
> ... and 24 more
> This note is generated from the file lists only; see the resolution record
> for the reasoning. ]
>
> Stable-dep-of: 546dde823a36 ("KVM: s390: Fix memory corruption by not reinjecting CK machine checks")
> Signed-off-by: Sasha Levin <sashal@kernel.org>
> ---
> arch/s390/include/asm/nmi.h | 4 ++--
> arch/s390/kvm/interrupt.c | 2 +-
> 2 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/arch/s390/include/asm/nmi.h b/arch/s390/include/asm/nmi.h
> index 227466ce9e416..6454c15318544 100644
> --- a/arch/s390/include/asm/nmi.h
> +++ b/arch/s390/include/asm/nmi.h
> @@ -33,7 +33,7 @@
> #define MCCK_CODE_FC_VALID BIT(63 - 43)
> #define MCCK_CODE_CPU_TIMER_VALID BIT(63 - 46)
>
> -#ifndef __ASSEMBLY__
> +#ifndef __ASSEMBLER__
>
> union mci {
> unsigned long val;
> @@ -104,5 +104,5 @@ void nmi_free_mcesa(u64 *mcesad);
> void s390_handle_mcck(void);
> void s390_do_machine_check(struct pt_regs *regs);
>
> -#endif /* __ASSEMBLY__ */
> +#endif /* __ASSEMBLER__ */
> #endif /* _ASM_S390_NMI_H */
> diff --git a/arch/s390/kvm/interrupt.c b/arch/s390/kvm/interrupt.c
> index 6f13144906417..3fc07da7fd7a5 100644
> --- a/arch/s390/kvm/interrupt.c
> +++ b/arch/s390/kvm/interrupt.c
> @@ -2863,7 +2863,7 @@ void kvm_s390_reinject_machine_check(struct kvm_vcpu *vcpu,
> struct mcck_volatile_info *mcck_info)
> {
> struct kvm_s390_interrupt_info inti;
> - struct kvm_s390_irq irq;
> + struct kvm_s390_irq irq = {};
> struct kvm_s390_mchk_info *mchk;
> union mci mci;
> __u64 cr14 = 0; /* upper bits are not used */
> --
> 2.53.0
>
>
did not apply
prev parent reply other threads:[~2026-09-30 13:45 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-09 10:35 FAILED: patch "[PATCH] KVM: s390: Fix memory corruption by not reinjecting CK" failed to apply to 6.12-stable tree gregkh
2026-09-11 11:22 ` [PATCH 6.12.y 1/2] s390: Replace __ASSEMBLY__ with __ASSEMBLER__ in non-uapi headers Sasha Levin
2026-09-11 11:22 ` [PATCH 6.12.y 2/2] KVM: s390: Fix memory corruption by not reinjecting CK machine checks Sasha Levin
2026-09-30 13:45 ` Greg KH [this message]
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=2026093056-clever-lustiness-56a5@gregkh \
--to=greg@kroah.com \
--cc=agordeev@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=sashal@kernel.org \
--cc=stable@vger.kernel.org \
--cc=thuth@redhat.com \
/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