All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vincent MAILHOL <mailhol.vincent@wanadoo.fr>
To: Nathan Chancellor <nathan@kernel.org>
Cc: Nick Desaulniers <ndesaulniers@google.com>,
	Tom Rix <trix@redhat.com>,
	 linux-kernel@vger.kernel.org, llvm@lists.linux.dev,
	 Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH] checksyscalls: ignore -Wunused-macros
Date: Mon, 25 Apr 2022 15:17:29 +0900	[thread overview]
Message-ID: <CAMZ6Rq+3XOze01dZZRTe+V44N2uo5J_=rtd9bKH7d7Fq9sNxVw@mail.gmail.com> (raw)
In-Reply-To: <YmXMiTXEvFXZ/swU@dev-arch.thelio-3990X>

Hi Nathan,

Thanks for the comments!

On Mon. 25 Apr 2022 at 07:17, Nathan Chancellor <nathan@kernel.org> wrote:
> Hi Vincent,
>
> On Sat, Apr 23, 2022 at 12:17:25AM +0900, Vincent Mailhol wrote:
> > The macros defined in this file are for testing only and are purposely
> > not used. When compiled with W=2, both gcc and clang yield some
> > -Wunused-macros warnings. Ignore them.
> >
> > Signed-off-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
>
> The change itself looks fine but a couple of comments:
>
> 1. Nick and I do not pick up patches, we rely on others to do so.
>    Additionally, this is not really something within our domain, despite
>    what get_maintainer.pl might say. This change should be sent to
>    either
>
>    Masahiro Yamada <masahiroy@kernel.org>
>    linux-kbuild@vger.kernel.org
>
>    or
>
>    Andrew Morton <akpm@linux-foundation.org>
>
>    so that it can be applied by one of them.

Ack. As you pointed out, I indeed just followed get_maintainer.pl.
I will resend a v2 to the people you pointed out (and exclude you).

> 2. I am not sure that silencing warnings from W=2 is that useful, as
>    they are unlikely to be real issues. Not to discourage you by any
>    means but it might be more useful to focus on cleaning up warnings
>    from W=1 and getting those promoted to regular build warnings.

Normally I agree, but there is one reason to fix this W=2: this
warning appears when building other files.

Example:
| $ make W=2 drivers/net/dummy.o
|   CALL    scripts/checksyscalls.sh
| <stdin>:21: warning: macro "__IGNORE_stat64" is not used [-Wunused-macros]
| <stdin>:22: warning: macro "__IGNORE_lstat64" is not used [-Wunused-macros]
| <stdin>:75: warning: macro "__IGNORE_llseek" is not used [-Wunused-macros]
| <stdin>:159: warning: macro "__IGNORE_madvise1" is not used [-Wunused-macros]
(rest of the output redacted).

When I run W=2, I want to only see the warnings of the file I am
working on. So I find it useful to fix the W=2 warnings which
show up when building other files to not get spammed by
irrelevant issues and to simplify the triage.

My initial message lacked the rationale. I will add additional
explanations in the v2 of this patch.


Yours sincerely,
Vincent Mailhol

  reply	other threads:[~2022-04-25  6:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-22 15:17 [PATCH] checksyscalls: ignore -Wunused-macros Vincent Mailhol
2022-04-24 22:17 ` Nathan Chancellor
2022-04-25  6:17   ` Vincent MAILHOL [this message]
2022-04-25  6:50     ` Arnd Bergmann
2022-04-25  7:42       ` Vincent MAILHOL
2022-04-25  8:49         ` Arnd Bergmann
2022-04-26 15:57           ` Vincent MAILHOL
2022-04-29 17:02 ` Masahiro Yamada

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='CAMZ6Rq+3XOze01dZZRTe+V44N2uo5J_=rtd9bKH7d7Fq9sNxVw@mail.gmail.com' \
    --to=mailhol.vincent@wanadoo.fr \
    --cc=arnd@arndb.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=nathan@kernel.org \
    --cc=ndesaulniers@google.com \
    --cc=trix@redhat.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 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.