[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdYautJ+aNrK+gqmAUzVCOgQH-WuXqEOn4FyW1hfeWa2zg@mail.gmail.com>
Date: Mon, 14 Dec 2020 10:05:30 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: Paul Cercueil <paul@...pouillou.net>
Cc: Arnd Bergmann <arnd@...nel.org>, od@...c.me,
"open list:GPIO SUBSYSTEM" <linux-gpio@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Zhou Yanjie <zhouyanjie@...yeetech.com>
Subject: Re: [PATCH v2 1/2] kconfig.h: Add IF_ENABLED() macro
On Mon, Dec 14, 2020 at 12:54 AM Paul Cercueil <paul@...pouillou.net> wrote:
> IF_ENABLED(CONFIG_FOO, ptr) evaluates to (ptr) if CONFIG_FOO is set to 'y'
> or 'm', NULL otherwise. The (ptr) argument must be a pointer.
>
> The IF_ENABLED() macro can be very useful to help GCC drop dead code.
I can apply this with the other patch to the pinctrl subsystem if Arnd or
someone else who is good at KConfig provides an ACK.
Yours,
Linus Walleij
Powered by blists - more mailing lists