Andy Shevchenko
0ea0908311
lib/cmdline: Allow get_options() to take 0 to validate the input
...
Allow get_options() to take 0 as a number of integers parameter to validate
the input.
Signed-off-by: Andy Shevchenko <[email protected] >
Reviewed-by: Geert Uytterhoeven <[email protected] >
2021-02-15 11:43:31 +01:00
Andy Shevchenko
d3c7cfc6d3
lib/cmdline_kunit: add a new test case for get_options()
...
Add a test case for get_options() which is provided by cmdline.c.
Signed-off-by: Andy Shevchenko <[email protected] >
2021-02-15 11:43:31 +01:00
Andy Shevchenko
7546861a8c
lib/cmdline_kunit: add a new test suite for cmdline API
...
Test get_option() for a starter which is provided by cmdline.c.
[[email protected] : fix warning by constifying cmdline_test_values]
[[email protected] : type of expected returned values should be int]
Link: https://lkml.kernel.org/r/[email protected]
[[email protected] : provide meaningful MODULE_LICENSE()]
Link: https://lkml.kernel.org/r/[email protected]
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Andy Shevchenko <[email protected] >
Cc: Shuah Khan <[email protected] >
Cc: Vitor Massaru Iha <[email protected] >
Cc: Mark Brown <[email protected] >
Cc: Brendan Higgins <[email protected] >
Cc: David Gow <[email protected] >
Cc: Matti Vaittinen <[email protected] >
Signed-off-by: Andrew Morton <[email protected] >
Signed-off-by: Linus Torvalds <[email protected] >
2020-12-15 22:46:16 -08:00