Messages in this thread | | | Date | Thu, 5 Nov 2020 19:02:15 +0100 | From | Petr Mladek <> | Subject | Re: [PATCH v3 1/3] Revert "kernel/reboot.c: convert simple_strtoul to kstrtoint" |
| |
On Tue 2020-11-03 22:40:23, Matteo Croce wrote: > From: Matteo Croce <mcroce@microsoft.com> > > This reverts commit 616feab753972b9751308f3cd2a68fc57eae8edb. > > kstrtoint() and simple_strtoul() have a subtle difference which makes > them non interchangeable: if a non digit character is found amid the > parsing, the former will return an error, while the latter will just > stop parsing, e.g. simple_strtoul("123xyx") = 123. > > The kernel cmdline reboot= argument allows to specify the CPU used > for rebooting, with the syntax `s####` among the other flags, > e.g. "reboot=warm,s31,force", so if this flag is not the last given, > it's silently ignored as well as the subsequent ones. > > Fixes: 616feab75397 ("kernel/reboot.c: convert simple_strtoul to kstrtoint") > Cc: stable@vger.kernel.org > Signed-off-by: Matteo Croce <mcroce@microsoft.com>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Best Regards, Petr
| |