From: Simon Horman <simon.horman@corigine.com>
To: Breno Leitao <leitao@debian.org>
Cc: "David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
leit@meta.com, Petr Mladek <pmladek@suse.com>,
"open list:NETWORKING DRIVERS" <netdev@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net-next 2/2] netconsole: Use kstrtobool() instead of kstrtoint()
Date: Mon, 24 Jul 2023 16:28:02 +0200 [thread overview]
Message-ID: <ZL6KcmKWCI3BtfUn@corigine.com> (raw)
In-Reply-To: <20230721092146.4036622-2-leitao@debian.org>
On Fri, Jul 21, 2023 at 02:21:45AM -0700, Breno Leitao wrote:
> Replace kstrtoint() by kstrtobool() in the sysfs _store() functions.
> This improves the user usability and simplify the code.
>
> With this fix, it is now possible to use [YyNn] to set and unset a
> feature. Old behaviour is still unchanged.
>
> kstrtobool() is also safer and doesn't need the extra validation that
> is required when converting a string to bool (end field in the struct),
> which makes the code simpler.
>
> Suggested-by: Petr Mladek <pmladek@suse.com>
> Signed-off-by: Breno Leitao <leitao@debian.org>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
next prev parent reply other threads:[~2023-07-24 14:28 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-21 9:21 [PATCH net-next 1/2] netconsole: Use sysfs_emit() instead of snprintf() Breno Leitao
2023-07-21 9:21 ` [PATCH net-next 2/2] netconsole: Use kstrtobool() instead of kstrtoint() Breno Leitao
2023-07-24 14:28 ` Simon Horman [this message]
2023-07-24 14:27 ` [PATCH net-next 1/2] netconsole: Use sysfs_emit() instead of snprintf() Simon Horman
2023-07-24 23:40 ` patchwork-bot+netdevbpf
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=ZL6KcmKWCI3BtfUn@corigine.com \
--to=simon.horman@corigine.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=leit@meta.com \
--cc=leitao@debian.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pmladek@suse.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;
as well as URLs for NNTP newsgroup(s).