All of lore.kernel.org
 help / color / mirror / Atom feed
From: Masahiro Yamada <yamada.masahiro@socionext.com>
To: Nick Desaulniers <ndesaulniers@google.com>
Cc: Joel Stanley <joel@jms.id.au>,
	Michal Marek <michal.lkml@markovi.net>,
	Linux Kbuild mailing list <linux-kbuild@vger.kernel.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] ftrace: Build with CPPFLAGS to get -Qunused-arguments
Date: Wed, 19 Sep 2018 23:54:44 +0900	[thread overview]
Message-ID: <CAK7LNAT9L==YS0a7FwuHTVaft2ONGd1b=GVExRrCYeLzW0sasw@mail.gmail.com> (raw)
In-Reply-To: <CAKwvOd=d4FdFzqimdq1os4gkk2JeeC4_-_ZbxVdkkPwd3KmuuQ@mail.gmail.com>

2018-09-18 2:24 GMT+09:00 Nick Desaulniers <ndesaulniers@google.com>:
> On Mon, Sep 17, 2018 at 12:38 AM Joel Stanley <joel@jms.id.au> wrote:
>>
>> When building to record the mcount locations the kernel uses
>> KBUILD_CFLAGS but not KBUILD_CPPFLAGS. This means it lacks
>> -Qunused-arguments when building with clang, resulting in a lot of
>> noisy warnings.
>>
>> Signed-off-by: Joel Stanley <joel@jms.id.au>
>> ---
>> Not sure why -Qunused-arguments is in CPP instead of KBUILD_CFLAGS. We
>> could instead put it in KBUILD_CFLAGS, and not need this patch.
>
> The preprocessor has flags that can change the definitions of macros.
> So there might be unused flags there.  I'm not a fan of covering up
> those warnings via -Qunused-arguments; the flags should be feature
> detected via cc-option and friends rather than always added then
> silenced if excessive.  That hides flags that are long dead/unused.
>
> Thanks for this patch!
> Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
>
>>
>>  scripts/Makefile.build | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>


Applied to linux-kbuild/fixes. Thanks!


-- 
Best Regards
Masahiro Yamada

      reply	other threads:[~2018-09-19 14:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-17  7:37 [PATCH] ftrace: Build with CPPFLAGS to get -Qunused-arguments Joel Stanley
2018-09-17 17:24 ` Nick Desaulniers
2018-09-19 14:54   ` Masahiro Yamada [this message]

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='CAK7LNAT9L==YS0a7FwuHTVaft2ONGd1b=GVExRrCYeLzW0sasw@mail.gmail.com' \
    --to=yamada.masahiro@socionext.com \
    --cc=joel@jms.id.au \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michal.lkml@markovi.net \
    --cc=ndesaulniers@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 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.