From: Randy Dunlap <rdunlap@infradead.org>
To: "Michal Koutný" <mkoutny@suse.com>
Cc: linux-mm@kvack.org, Igor Zhbanov <i.zhbanov@omprussia.ru>,
Andrew Morton <akpm@linux-foundation.org>,
Johannes Weiner <hannes@cmpxchg.org>,
Michal Hocko <mhocko@kernel.org>,
Vladimir Davydov <vdavydov.dev@gmail.com>,
cgroups@vger.kernel.org
Subject: Re: [PATCH 1/2] mm/memcontrol: return 1 from cgroup.memory __setup() handler
Date: Thu, 3 Mar 2022 14:53:59 -0800 [thread overview]
Message-ID: <8c61e14d-493d-ecea-6bc5-076781e8e93d@infradead.org> (raw)
In-Reply-To: <YiFCAFZwG//aeQP2@blackbook>
On 3/3/22 14:32, Michal Koutný wrote:
> On Thu, Mar 03, 2022 at 01:53:03PM -0800, Randy Dunlap <rdunlap@infradead.org> wrote:
>>> Isn't mere presence of the handler sufficient to filter those out? [1]
>>
>> What is [1] here?
>
> Please ignore, too much editing on my side.
>
>> I don't know of any case where "foo=2" should be passed to init if
>> there is a setup function for "foo=" defined.
>
> Good. I was asking because of the following semantics:
> - absent handler -- pass to init,
Ack: if the handler code is not built, it is an Unknown boot option
and is passed to init.
> - returns 0 -- filter out,
> - returns negative -- filter out, print message.
Currently setup functions should return 1 (or any non-zero value)
to indicate "handled" or should return 0 to indicate "not handled".
Andrew has a patch in mmotm: include/linux/init.h so that the comment
before __setup() says:
/*
* NOTE: __setup functions return values:
* @fn returns 1 (or non-zero) if the option argument is "handled"
* and returns 0 if the option argument is "not handled".
*/
>>> (Richer reporting or -EINVAL is by my understanding now a different
>>> problem.)
--
~Randy
prev parent reply other threads:[~2022-03-03 22:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-22 0:58 Randy Dunlap
2022-03-02 18:53 ` Michal Koutný
2022-03-03 0:53 ` Randy Dunlap
2022-03-03 10:14 ` Michal Koutný
2022-03-03 21:53 ` Randy Dunlap
2022-03-03 22:32 ` Michal Koutný
2022-03-03 22:53 ` Randy Dunlap [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=8c61e14d-493d-ecea-6bc5-076781e8e93d@infradead.org \
--to=rdunlap@infradead.org \
--cc=akpm@linux-foundation.org \
--cc=cgroups@vger.kernel.org \
--cc=hannes@cmpxchg.org \
--cc=i.zhbanov@omprussia.ru \
--cc=linux-mm@kvack.org \
--cc=mhocko@kernel.org \
--cc=mkoutny@suse.com \
--cc=vdavydov.dev@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox