]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
lib/cmdline: adjust a few comments to fix kernel-doc -Wreturn warnings
authorDmitry Antipov <dmantipov@yandex.ru>
Tue, 19 May 2026 17:22:56 +0000 (20:22 +0300)
committerAndrew Morton <akpm@linux-foundation.org>
Fri, 29 May 2026 04:24:50 +0000 (21:24 -0700)
Fix 'get_option()', 'memparse()' and 'parse_option_str()' comments to
match the commonly used style as suggested by kernel-doc -Wreturn.

Link: https://lore.kernel.org/20260519172259.908980-6-dmantipov@yandex.ru
Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>
Suggested-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Cc: Albert Ou <aou@eecs.berkeley.edu>
Cc: Alexandre Ghiti <alex@ghiti.fr>
Cc: Ard Biesheuvel <ardb@kernel.org>
Cc: Charlie Jenkins <thecharlesjenkins@gmail.com>
Cc: Palmer Dabbelt <palmer@dabbelt.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
lib/cmdline.c

index f6e4b113ca9f80a25d5c7bed55dadd97cc5e9313..16cce6621cec186aa5feb0f8bea9d7a4fa1a444f 100644 (file)
@@ -43,7 +43,7 @@ static int get_range(char **str, int *pint, int n)
  *     When @pint is NULL the function can be used as a validator of
  *     the current option in the string.
  *
- *     Return values:
+ *     Return:
  *     0 - no int in string
  *     1 - int found, no subsequent comma
  *     2 - int found including a subsequent comma
@@ -145,6 +145,9 @@ EXPORT_SYMBOL(get_options);
  *
  *     Parses a string into a number.  The number stored at @ptr is
  *     potentially suffixed with K, M, G, T, P, E.
+ *
+ *     Return: The value as recognized by simple_strtoull() multiplied
+ *     by the value as specified by suffix, if any.
  */
 
 unsigned long long memparse(const char *ptr, char **retptr)
@@ -205,7 +208,7 @@ EXPORT_SYMBOL(memparse);
  *     This function parses a string containing a comma-separated list of
  *     strings like a=b,c.
  *
- *     Return true if there's such option in the string, or return false.
+ *     Return: True if there's such option in the string or false otherwise.
  */
 bool parse_option_str(const char *str, const char *option)
 {