[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2a5500a5-c1b6-4c5c-bf37-4cfeda5a9e1e@gmail.com>
Date: Sat, 16 Nov 2024 09:18:21 +0530
From: R Sundar <prosunofficial@...il.com>
To: Andy Shevchenko <andy.shevchenko@...il.com>
Cc: Kees Cook <kees@...nel.org>, Andy Shevchenko <andy@...nel.org>,
linux-hardening@...r.kernel.org, linux-kernel@...r.kernel.org,
Przemek Kitszel <przemyslaw.kitszel@...el.com>
Subject: Re: [PATCH linux-next] lib/string_choices: Add
str_locked_unlocked()/str_unlocked_locked() helper
On 16/11/24 01:16, Andy Shevchenko wrote:
> On Fri, Nov 15, 2024 at 9:44 PM Andy Shevchenko
> <andy.shevchenko@...il.com> wrote:
>> On Fri, Nov 15, 2024 at 4:47 PM R Sundar <prosunofficial@...il.com> wrote:
>
> ...
>
>>> --- a/include/linux/string_choices.h
>>> +++ b/include/linux/string_choices.h
>>> @@ -82,4 +82,10 @@ static inline const char *str_plural(size_t num)
>>> return num == 1 ? "" : "s";
>>> }
>>>
>>> +static inline const char *str_locked_unlocked(bool v)
>>> +{
>>> + return v ? "locked" : "unlocked";
>>> +}
>>> +#define str_unlocked_locked(v) str_locked_unlocked(!(v))
>>
>> The rest is sorted (okay, read_write() seems to be misplaced, fix that
>> in a separate change if you wish), please keep it that way (I believe
>> it should go before on_off).
>
Hi,
Thanks for the Review and Comments provided.
Please correct me, If I am wrong.
The function name should be in sorted order means, str_read_write()
will go after str_on_off().
For example, the sorted order of function will be like:
str_on_off()
str_plural()
str_read_write()
> Oh, I looked in v6.11 code, in v6.12 there are a couple of more
> misplacements. Can you fix them all, please?
>
Sure, Will sort it and send as seperate patch.
Thanks,
Sundar
Powered by blists - more mailing lists