diff options
| author | Jagdish Gediya <[email protected]> | 2022-05-12 20:22:59 -0700 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2022-05-13 07:20:13 -0700 |
| commit | 0d6ea3ac94ca77c5273b064524ac5079312052a0 (patch) | |
| tree | 624fe1f72eb952b06d7bef8f99bb1aa1dcd09725 /tools/perf/scripts/python/bin | |
| parent | d8ff6fde8e88d801b62328883680c202510ed518 (diff) | |
lib/kstrtox.c: add "false"/"true" support to kstrtobool()
At many places in kernel, It is necessary to convert sysfs input to
corresponding bool value e.g. "false" or "0" need to be converted to bool
false, "true" or "1" need to be converted to bool true, places where such
conversion is needed currently check the input string manually,
kstrtobool() can be utilized at such places but currently it doesn't have
support to accept "false"/"true".
Add support to accept "false"/"true" as valid string in kstrtobool().
[[email protected]: undo s/iff/if/, per Matthew]
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Jagdish Gediya <[email protected]>
Reviewed-by: Matthew Wilcox (Oracle) <[email protected]>
Reviewed-by: Andy Shevchenko <[email protected]>
Cc: "Huang, Ying" <[email protected]>
Cc: Dave Hansen <[email protected]>
Cc: Jonathan Cameron <[email protected]>
Cc: Alexey Dobriyan <[email protected]>
Cc: Richard Fitzgerald <[email protected]>
Cc: Petr Mladek <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions