Re: [PATCH] kbuild: Enable -Wimplicit-fallthrough for clang 14.0.0+

From: Linus Torvalds
Date: Tue Aug 17 2021 - 00:38:52 EST

On Mon, Aug 16, 2021 at 6:20 PM Nathan Chancellor <nathan@xxxxxxxxxx> wrote:
> Additionally, there should be some time for the CI systems to update
> their clang-14 builds, as the recent 0day report shows.


No, the 0day report shows that the patch is buggy, and that the

ifeq ($(shell test $(CONFIG_CLANG_VERSION) -ge 140000; echo $$?),0)

clearly doesn't work at all, since the flag is enabled on those
systems with old clang versions.

Alternatively, the test works, but the 140000 version is not enough.

So no. This patch is simply completely wrong, and doesn't fix the
problem with Clang's buggy -Wimplicit-fallthrough flag.