From: Kees Cook <kees@kernel.org>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>,
linux-hardening@vger.kernel.org
Subject: Re: [PATCH 1/2] lib/string_choices: Add str_up_down() helper
Date: Thu, 8 Aug 2024 10:57:29 -0700 [thread overview]
Message-ID: <202408081055.60B7E5935@keescook> (raw)
In-Reply-To: <ZrSLdCwtZA-iB1L-@smile.fi.intel.com>
On Thu, Aug 08, 2024 at 12:10:12PM +0300, Andy Shevchenko wrote:
> On Thu, Jul 25, 2024 at 12:18:40PM +0200, Michal Wajdeczko wrote:
> > Add str_up_down() helper to return "up" or "down" string literal.
>
> ...
>
> > +static inline const char *str_up_down(bool v)
> > +{
> > + return v ? "up" : "down";
> > +}
>
> Can you please add a respective macro for str_down_up() as it's done for (some)
> others?
e.g.
#define str_down_up(v) str_up_down(!(v))
--
Kees Cook
prev parent reply other threads:[~2024-08-08 17:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-25 10:18 [PATCH 1/2] lib/string_choices: Add str_up_down() helper Michal Wajdeczko
2024-07-25 10:18 ` [PATCH 2/2] coccinelle: Add rules to find str_up_down() replacements Michal Wajdeczko
2024-08-08 9:11 ` Andy Shevchenko
2024-08-06 4:40 ` [PATCH 1/2] lib/string_choices: Add str_up_down() helper Kees Cook
2024-08-08 9:10 ` Andy Shevchenko
2024-08-08 17:57 ` Kees Cook [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=202408081055.60B7E5935@keescook \
--to=kees@kernel.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=linux-hardening@vger.kernel.org \
--cc=michal.wajdeczko@intel.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.