From: "Arnd Bergmann" <arnd@arndb.de>
To: "Nathan Chancellor" <nathan@kernel.org>,
"Masahiro Yamada" <masahiroy@kernel.org>
Cc: "Nicolas Schier" <nicolas@fjasle.eu>,
"Nick Desaulniers" <ndesaulniers@google.com>,
"Bill Wendling" <morbo@google.com>,
"Justin Stitt" <justinstitt@google.com>,
"Aleksei Vetrov" <vvvvvv@google.com>,
linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org,
llvm@lists.linux.dev, patches@lists.linux.dev,
stable@vger.kernel.org
Subject: Re: [PATCH v2] kbuild: Move -Wenum-enum-conversion to W=2
Date: Thu, 17 Oct 2024 20:19:54 +0000 [thread overview]
Message-ID: <079876f3-19c6-41bf-8e70-8764fd4c62e4@app.fastmail.com> (raw)
In-Reply-To: <20241017-disable-two-clang-enum-warnings-v2-1-163ac04346ae@kernel.org>
On Thu, Oct 17, 2024, at 17:09, Nathan Chancellor wrote:
> -Wenum-enum-conversion was strengthened in clang-19 to warn for C, which
> caused the kernel to move it to W=1 in commit 75b5ab134bb5 ("kbuild:
> Move -Wenum-{compare-conditional,enum-conversion} into W=1") because
> there were numerous instances that would break builds with -Werror.
> Unfortunately, this is not a full solution, as more and more developers,
> subsystems, and distributors are building with W=1 as well, so they
> continue to see the numerous instances of this warning.
>
> Since the move to W=1, there have not been many new instances that have
> appeared through various build reports and the ones that have appeared
> seem to be following similar existing patterns, suggesting that most
> instances of this warning will not be real issues. The only alternatives
> for silencing this warning are adding casts (which is generally seen as
> an ugly practice) or refactoring the enums to macro defines or a unified
> enum (which may be undesirable because of type safety in other parts of
> the code).
>
> Move the warning to W=2, where warnings that occur frequently but may be
> relevant should reside.
>
> Cc: stable@vger.kernel.org
> Fixes: 75b5ab134bb5 ("kbuild: Move
> -Wenum-{compare-conditional,enum-conversion} into W=1")
> Link: https://lore.kernel.org/ZwRA9SOcOjjLJcpi@google.com/
> Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>
next prev parent reply other threads:[~2024-10-17 20:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-17 17:09 Nathan Chancellor
2024-10-17 20:19 ` Arnd Bergmann [this message]
2024-12-02 16:16 ` Nathan Chancellor
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=079876f3-19c6-41bf-8e70-8764fd4c62e4@app.fastmail.com \
--to=arnd@arndb.de \
--cc=justinstitt@google.com \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=llvm@lists.linux.dev \
--cc=masahiroy@kernel.org \
--cc=morbo@google.com \
--cc=nathan@kernel.org \
--cc=ndesaulniers@google.com \
--cc=nicolas@fjasle.eu \
--cc=patches@lists.linux.dev \
--cc=stable@vger.kernel.org \
--cc=vvvvvv@google.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
all inboxes | Powered by JetHome®