[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <dbx8cy3wso46.fsf@ynaffit-andsys.c.googlers.com>
Date: Mon, 29 Dec 2025 18:24:41 -0800
From: Tiffany Yang <ynaffit@...gle.com>
To: Justin Stitt <justinstitt@...gle.com>
Cc: Marc Zyngier <maz@...nel.org>, Oliver Upton <oliver.upton@...ux.dev>,
Alexandru Elisei <alexandru.elisei@....com>, Joey Gouly <joey.gouly@....com>,
Suzuki K Poulose <suzuki.poulose@....com>, Catalin Marinas <catalin.marinas@....com>,
Zenghui Yu <yuzenghui@...wei.com>, Will Deacon <will@...nel.org>,
Nathan Chancellor <nathan@...nel.org>, Christopher Covington <cov@...eaurora.org>,
linux-arm-kernel@...ts.infradead.org, kvmarm@...ts.cs.columbia.edu,
linux-kernel@...r.kernel.org, llvm@...ts.linux.dev, stable@...r.kernel.org
Subject: Re: [PATCH 5.15.y RESEND] KVM: arm64: sys_regs: disable
-Wuninitialized-const-pointer warning
Justin Stitt <justinstitt@...gle.com> writes:
> A new warning in Clang 22 [1] complains that @clidr passed to
> get_clidr_el1() is an uninitialized const pointer. get_clidr_el1()
> doesn't really care since it casts away the const-ness anyways -- it is
> a false positive.
> | ../arch/arm64/kvm/sys_regs.c:2838:23: warning: variable 'clidr' is
> uninitialized when passed as a const pointer argument here
> [-Wuninitialized-const-pointer]
> | 2838 | get_clidr_el1(NULL, &clidr); /* Ugly... */
> | | ^~~~~
> This patch isn't needed for anything past 6.1 as this code section was
> reworked in Commit 7af0c2534f4c ("KVM: arm64: Normalize cache
> configuration"). Since there is no upstream equivalent, this patch just
> needs to be applied to 5.15.
This error has also been showing up in 5.10 since KernelCI started using
clang-21.
> Disable this warning for sys_regs.o with an iron fist as it doesn't make
> sense to waste maintainer's time or potentially break builds by
> backporting large changelists from 6.2+.
> Cc: stable@...r.kernel.org
> Fixes: 7c8c5e6a9101e ("arm64: KVM: system register handling")
> Link:
> https://github.com/llvm/llvm-project/commit/00dacf8c22f065cb52efb14cd091d441f19b319e
> [1]
> Reviewed-by: Nathan Chancellor <nathan@...nel.org>
> Signed-off-by: Justin Stitt <justinstitt@...gle.com>
<snip>
Reviewed-by: Tiffany Yang <ynaffit@...gle.com>
--
Tiffany Y. Yang
Powered by blists - more mailing lists