Re: [PATCH] kvm: arm64: use BUG() instead of BUG_ON(1)

From: Oliver Upton
Date: Fri Aug 08 2025 - 13:52:29 EST


On Thu, 07 Aug 2025 09:21:28 +0200, Arnd Bergmann wrote:
> The BUG_ON() macro adds a little bit of complexity over BUG(), and in
> some cases this ends up confusing the compiler's control flow analysis
> in a way that results in a warning. This one now shows up with clang-21:
>
> arch/arm64/kvm/vgic/vgic-mmio.c:1094:3: error: variable 'len' is used uninitialized whenever 'if' condition is false [-Werror,-Wsometimes-uninitialized]
> 1094 | BUG_ON(1);
>
> [...]

Applied to fixes, thanks!

[1/1] kvm: arm64: use BUG() instead of BUG_ON(1)
https://git.kernel.org/kvmarm/kvmarm/c/700d6868fee2

--
Best,
Oliver