[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3741c271-51a7-ed99-673e-18a7356df971@rasmusvillemoes.dk>
Date: Tue, 28 Jun 2022 14:17:04 +0200
From: Rasmus Villemoes <linux@...musvillemoes.dk>
To: Arnd Bergmann <arnd@...db.de>,
Peter Zijlstra <peterz@...radead.org>
Cc: Masahiro Yamada <masahiroy@...nel.org>, mmarek@...e.cz,
Paul Gortmaker <paul.gortmaker@...driver.com>,
Mike Rapoport <rppt@...nel.org>,
Borislav Petkov <bp@...en8.de>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [RFC][PATCH] kconfig: Add implicit CONFIG_ prefix to IS_ENABLED()
and co
On 28/06/2022 13.19, Arnd Bergmann wrote:
> On Tue, Jun 28, 2022 at 11:56 AM Peter Zijlstra <peterz@...radead.org> wrote:
>>
>> Since IS_ENABLED() (and friends) are clearly meant to be used on
>> CONFIG_foo symbols and IS_ENABLED(CONFIG_ is so long and almost an
>> tautology, allow the more compact usage of: IS_ENABLED(foo).
>>
>> Signed-off-by: Peter Zijlstra (Intel) <peterz@...radead.org>
>
> I'd prefer to keep the more verbose usage, mainly because it makes it easier
> to grep for a symbol. If today you do 'git grep CONFIG_PM_SLEEP', you find
> all instances in Makefile, in #ifdef and in IS_ENABLED(), though not the
> references in Kconfig language, which leave out the prefix.
Agreed.
Also, having CONFIG_ added implicitly requires updating fixdep, and that
will probably make the fixdep step somewhat more expensive - because one
would still have to find all explicit CONFIG_SOMETHING (they'd still be
used in ifdefs, and the int and string options directly in code), but in
addition also grep for IS_ENABLED, IS_BUILTIN, IS_MODULE.
Rasmus
Powered by blists - more mailing lists