From: Greg KH <gregkh@linuxfoundation.org>
To: Clark Williams <clrkwllms@kernel.org>
Cc: stable@vger.kernel.org, sashal@kernel.org
Subject: Re: [PATCH linux-6.1.y 0/2]
Date: Tue, 16 Jun 2026 15:49:49 +0530 [thread overview]
Message-ID: <2026061644-upstairs-reversion-7a16@gregkh> (raw)
In-Reply-To: <20260616013306.3850069-1-clrkwllms@kernel.org>
On Mon, Jun 15, 2026 at 08:33:04PM -0500, Clark Williams wrote:
> GCC 16.1.1 introduces stricter diagnostics that surface two latent issues
> in the 6.1.y stable tree, both of which become hard errors under -Werror:
>
> 1. -Wattributes on regparm(0) for x86-64
> arch/x86/kvm/vmx/vmx_ops.h applies __attribute__((regparm(0))) to
> vmread_error_trampoline(). On x86-32 this is intentional: it overrides
> the kernel's -mregparm=3 convention so the trampoline receives its
> arguments on the stack, matching the inline-asm callers that push args
> before the call. On x86-64 the attribute has always been a no-op (the
> SysV ABI already passes arguments in registers), but older GCC silently
> accepted it. GCC 16.1.1 now warns, which -Werror promotes to a build
> failure. The fix guards the attribute with #ifdef CONFIG_X86_32.
>
> 2. -Wdiscarded-qualifiers in libbpf
> In tools/lib/bpf/libbpf.c, resolve_full_path() assigns the result
> of strchr() on a const char * to a plain char * variable. Newer
> GCC/glibc combinations propagate the const qualifier through strchr(),
> so this assignment now triggers -Werror=discarded-qualifiers. Since the
> variable (next_path) is only used for pointer arithmetic and is never
> written through, the fix is simply to declare it const char *.
>
> Clark Williams (2):
> tools/lib/bpf: fix const-qualifier discard in resolve_full_path
> kvm/vmx: guard regparm(0) on vmread_error_trampoline for x86_32 only
>
> arch/x86/kvm/vmx/vmx_ops.h | 7 +++++--
> tools/lib/bpf/libbpf.c | 2 +-
> 2 files changed, 6 insertions(+), 3 deletions(-)
>
>
> --
> 2.54.0
>
>
<formletter>
This is not the correct way to submit patches for inclusion in the
stable kernel tree. Please read:
https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
for how to do this properly.
</formletter>
prev parent reply other threads:[~2026-06-16 10:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-16 1:33 [PATCH linux-6.1.y 0/2] Clark Williams
2026-06-16 1:33 ` [PATCH linux-6.1.y 1/2] tools/lib/bpf: fix const-qualifier discard in resolve_full_path Clark Williams
2026-06-16 1:33 ` [PATCH linux-6.1.y 2/2] kvm/vmx: guard regparm(0) on vmread_error_trampoline for x86_32 only Clark Williams
2026-06-16 10:19 ` 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=2026061644-upstairs-reversion-7a16@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=clrkwllms@kernel.org \
--cc=sashal@kernel.org \
--cc=stable@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.