linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] certs: Fix some kernel-doc comments
@ 2022-04-02  7:31 Yang Li
  0 siblings, 0 replies; 3+ messages in thread
From: Yang Li @ 2022-04-02  7:31 UTC (permalink / raw)
  To: dhowells; +Cc: dwmw2, keyrings, linux-kernel, Yang Li, Abaci Robot

Remove some warnings found by running scripts/kernel-doc,
which is caused by using 'make W=1'.

certs/system_keyring.c:46: warning: expecting prototype for
restrict_link_to_builtin_trusted(). Prototype was for
restrict_link_by_builtin_trusted() instead
certs/system_keyring.c:80: warning: This comment starts with '/**', but
isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
---

--Changes in v2:
  turn the "/**" into "/*".

 certs/system_keyring.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/certs/system_keyring.c b/certs/system_keyring.c
index 05b66ce9d1c9..62d37dc0ca81 100644
--- a/certs/system_keyring.c
+++ b/certs/system_keyring.c
@@ -34,7 +34,7 @@ extern __initconst const unsigned long system_certificate_list_size;
 extern __initconst const unsigned long module_cert_size;
 
 /**
- * restrict_link_to_builtin_trusted - Restrict keyring addition by built in CA
+ * restrict_link_by_builtin_trusted - Restrict keyring addition by built in CA
  *
  * Restrict the addition of keys into a keyring based on the key-to-be-added
  * being vouched for by a key in the built in system keyring.
@@ -76,7 +76,7 @@ int restrict_link_by_builtin_and_secondary_trusted(
 					  secondary_trusted_keys);
 }
 
-/**
+/*
  * Allocate a struct key_restriction for the "builtin and secondary trust"
  * keyring. Only for use in system_trusted_keyring_init().
  */
-- 
2.20.1.7.g153144c


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH -next] certs: Fix some kernel-doc comments
  2022-03-17  2:12 Yang Li
@ 2022-03-31 12:56 ` David Howells
  0 siblings, 0 replies; 3+ messages in thread
From: David Howells @ 2022-03-31 12:56 UTC (permalink / raw)
  To: Yang Li; +Cc: dhowells, dwmw2, keyrings, linux-kernel, Abaci Robot

Yang Li <yang.lee@linux.alibaba.com> wrote:

>  /**
> - * Allocate a struct key_restriction for the "builtin and secondary trust"
> - * keyring. Only for use in system_trusted_keyring_init().
> + * get_builtin_and_secondary_restriction - Allocate a struct key_restriction
> + * for the "builtin and secondary trust" keyring. Only for use in
> + * system_trusted_keyring_init().
>   */
>  static __init struct key_restriction *get_builtin_and_secondary_restriction(void)

Better to just turn the "/**" into "/*" for this one.  It's not a function
that should necessarily appear in API docs.

David


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH -next] certs: Fix some kernel-doc comments
@ 2022-03-17  2:12 Yang Li
  2022-03-31 12:56 ` David Howells
  0 siblings, 1 reply; 3+ messages in thread
From: Yang Li @ 2022-03-17  2:12 UTC (permalink / raw)
  To: dhowells; +Cc: dwmw2, keyrings, linux-kernel, Yang Li, Abaci Robot

Remove some warnings found by running scripts/kernel-doc,
which is caused by using 'make W=1'.

certs/system_keyring.c:46: warning: expecting prototype for
restrict_link_to_builtin_trusted(). Prototype was for
restrict_link_by_builtin_trusted() instead
certs/system_keyring.c:80: warning: This comment starts with '/**', but
isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
---
 certs/system_keyring.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/certs/system_keyring.c b/certs/system_keyring.c
index 05b66ce9d1c9..f0eb8c680cac 100644
--- a/certs/system_keyring.c
+++ b/certs/system_keyring.c
@@ -34,7 +34,7 @@ extern __initconst const unsigned long system_certificate_list_size;
 extern __initconst const unsigned long module_cert_size;
 
 /**
- * restrict_link_to_builtin_trusted - Restrict keyring addition by built in CA
+ * restrict_link_by_builtin_trusted - Restrict keyring addition by built in CA
  *
  * Restrict the addition of keys into a keyring based on the key-to-be-added
  * being vouched for by a key in the built in system keyring.
@@ -77,8 +77,9 @@ int restrict_link_by_builtin_and_secondary_trusted(
 }
 
 /**
- * Allocate a struct key_restriction for the "builtin and secondary trust"
- * keyring. Only for use in system_trusted_keyring_init().
+ * get_builtin_and_secondary_restriction - Allocate a struct key_restriction
+ * for the "builtin and secondary trust" keyring. Only for use in
+ * system_trusted_keyring_init().
  */
 static __init struct key_restriction *get_builtin_and_secondary_restriction(void)
 {
-- 
2.20.1.7.g153144c


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-04-02  7:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-02  7:31 [PATCH -next] certs: Fix some kernel-doc comments Yang Li
  -- strict thread matches above, loose matches on Subject: below --
2022-03-17  2:12 Yang Li
2022-03-31 12:56 ` David Howells

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).