Skip to contentSkip to conversation

powerpc: boot: Fix a typo in partial_decompress() comment

PATCH In review Yang Li 3 participants 7 messages Apr 7, 2024 – Apr 8, 2024

Subsystems (2)
lore
Share & tools
lore

Yang Li

author
#0 lore raw

PATCH 1/3 powerpc: boot: Fix a typo in partial_decompress() comment

This commit adds kernel-doc style comments with complete parameter descriptions for the function partial_decompress().

---
 arch/powerpc/boot/decompress.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/powerpc/boot/decompress.c +1 -1
index 977eb15a6d17..6835cb53f034 100644
@@ -101,7 +101,7 @@ static void print_err(char *s)
  * @input_size:  length of the input buffer
  * @outbuf:      output buffer
  * @output_size: length of the output buffer
- * @skip         number of output bytes to ignore
+ * @_skip:       number of output bytes to ignore
  *
  * This function takes compressed data from inbuf, decompresses and write it to
  * outbuf. Once output_size bytes are written to the output buffer, or the
Signature · 1 line
2.20.1.7.g153144c
author
#1 lore raw

PATCH 2/3 powerpc: Fix kernel-doc comments in fsl_gtm.c

Fix some function names in kernel-doc comments.

---
 arch/powerpc/sysdev/fsl_gtm.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
arch/powerpc/sysdev/fsl_gtm.c +3 -3
index 39186ad6b3c3..71e07883eb48 100644
@@ -77,7 +77,7 @@ struct gtm {
 static LIST_HEAD(gtms);
 
 /**
- * gtm_get_timer - request GTM timer to use it with the rest of GTM API
+ * gtm_get_timer16 - request GTM timer to use it with the rest of GTM API
  * Context:	non-IRQ
  *
  * This function reserves GTM timer for later use. It returns gtm_timer
@@ -110,7 +110,7 @@ struct gtm_timer *gtm_get_timer16(void)
 EXPORT_SYMBOL(gtm_get_timer16);
 
 /**
- * gtm_get_specific_timer - request specific GTM timer
+ * gtm_get_specific_timer16 - request specific GTM timer
  * @gtm:	specific GTM, pass here GTM's device_node->data
  * @timer:	specific timer number, Timer1 is 0.
  * Context:	non-IRQ
@@ -276,7 +276,7 @@ EXPORT_SYMBOL(gtm_set_timer16);
  * crop precision of the "usec" argument, thus usec is limited to 16 bits
  * (single timer width).
  */
-int gtm_set_exact_timer16(struct gtm_timer *tmr, u16 usec, bool reload)
+int gtm_set_exact_utimer16(struct gtm_timer *tmr, u16 usec, bool reload)
 {
 	/* quite obvious, frequency which is enough for µSec precision */
 	const int freq = 1000000;
Signature · 1 line
2.20.1.7.g153144c
#2 lore raw

Re: [PATCH -next 2/3] powerpc: Fix kernel-doc comments in fsl_gtm.c

Quoted 12 lines · Yang Li

Fix some function names in kernel-doc comments.

---
 arch/powerpc/sysdev/fsl_gtm.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
arch/powerpc/sysdev/fsl_gtm.c +0 -0
index 39186ad6b3c3..71e07883eb48 100644

arch/powerpc/sysdev/fsl_gtm.c struct gtm { · line 80

Quoted 5 lines
arch/powerpc/sysdev/fsl_gtm.c +1 -1
@@ -77,7 +77,7 @@ struct gtm {
 static LIST_HEAD(gtms);
 
 /**
- * gtm_get_timer - request GTM timer to use it with the rest of GTM API
+ * gtm_get_timer16 - request GTM timer to use it with the rest of GTM API

ack

arch/powerpc/sysdev/fsl_gtm.c struct gtm_timer *gtm_get_timer16(void) · line 113

Quoted 9 lines
arch/powerpc/sysdev/fsl_gtm.c +1 -1
  * Context:	non-IRQ
  *
  * This function reserves GTM timer for later use. It returns gtm_timer
@@ -110,7 +110,7 @@ struct gtm_timer *gtm_get_timer16(void)
 EXPORT_SYMBOL(gtm_get_timer16);
 
 /**
- * gtm_get_specific_timer - request specific GTM timer
+ * gtm_get_specific_timer16 - request specific GTM timer

ack

arch/powerpc/sysdev/fsl_gtm.c EXPORT_SYMBOL(gtm_set_timer16); · line 279

Quoted 9 lines
arch/powerpc/sysdev/fsl_gtm.c +1 -1
  * @gtm:	specific GTM, pass here GTM's device_node->data
  * @timer:	specific timer number, Timer1 is 0.
  * Context:	non-IRQ
@@ -276,7 +276,7 @@ EXPORT_SYMBOL(gtm_set_timer16);
  * crop precision of the "usec" argument, thus usec is limited to 16 bits
  * (single timer width).
  */
-int gtm_set_exact_timer16(struct gtm_timer *tmr, u16 usec, bool reload)
+int gtm_set_exact_utimer16(struct gtm_timer *tmr, u16 usec, bool reload)

No, change the kernel-doc comment instead. Otherwise the caller will fail to link.

arch/powerpc/sysdev/fsl_gtm.c EXPORT_SYMBOL(gtm_set_timer16); · line 282

Quoted 3 lines
arch/powerpc/sysdev/fsl_gtm.c +0 -0
 {
 	/* quite obvious, frequency which is enough for µSec precision */
 	const int freq = 1000000;

thanks.

Signature · 1 line
#Randy
author
#3 lore raw

PATCH 3/3 powerpc/rtas: Add kernel-doc comments to smp_startup_cpu()

In reply to Yang Li

This commit adds kernel-doc style comments with complete parameter descriptions for the function smp_startup_cpu().

---
 arch/powerpc/platforms/cell/smp.c | 2 ++
 1 file changed, 2 insertions(+)
arch/powerpc/platforms/cell/smp.c +2 -0
index 30394c6f8894..bdb7adde798d 100644
@@ -55,6 +55,8 @@ static cpumask_t of_spin_map;
 /**
  * smp_startup_cpu() - start the given cpu
  *
+ * @lcpu: Logical CPU ID of the CPU to be started.
+ *
  * At boot time, there is nothing to do for primary threads which were
  * started from Open Firmware.  For anything else, call RTAS with the
  * appropriate start location.
Signature · 1 line
2.20.1.7.g153144c
#4 lore raw

Re: [PATCH -next 3/3] powerpc/rtas: Add kernel-doc comments to smp_startup_cpu()

Quoted 13 lines · Yang Li

This commit adds kernel-doc style comments with complete parameter descriptions for the function smp_startup_cpu().

---
 arch/powerpc/platforms/cell/smp.c | 2 ++
 1 file changed, 2 insertions(+)
arch/powerpc/platforms/cell/smp.c +0 -0
index 30394c6f8894..bdb7adde798d 100644

arch/powerpc/platforms/cell/smp.c static cpumask_t of_spin_map; · line 58

Quoted 4 lines
arch/powerpc/platforms/cell/smp.c +1 -0
@@ -55,6 +55,8 @@ static cpumask_t of_spin_map;
 /**
  * smp_startup_cpu() - start the given cpu
  *
+ * @lcpu: Logical CPU ID of the CPU to be started.

Does this work with the blank line between the function and parameter? (i.e., no kernel-doc warnings?)

Usually it's done without the extra line. Otherwise the additional line for @lcpu: looks good to me.

Thanks.

Quoted 4 lines
arch/powerpc/platforms/cell/smp.c +1 -0
+ *
  * At boot time, there is nothing to do for primary threads which were
  * started from Open Firmware.  For anything else, call RTAS with the
  * appropriate start location.
Signature · 1 line
#Randy
Reviewed-by on v1 1/3
#5 lore raw
In reply to Yang Li
Quoted 4 lines · Yang Li

This commit adds kernel-doc style comments with complete parameter descriptions for the function partial_decompress().

Thanks.

Quoted 17 lines
---
 arch/powerpc/boot/decompress.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/powerpc/boot/decompress.c +1 -1
index 977eb15a6d17..6835cb53f034 100644
@@ -101,7 +101,7 @@ static void print_err(char *s)
  * @input_size:  length of the input buffer
  * @outbuf:      output buffer
  * @output_size: length of the output buffer
- * @skip         number of output bytes to ignore
+ * @_skip:       number of output bytes to ignore
  *
  * This function takes compressed data from inbuf, decompresses and write it to
  * outbuf. Once output_size bytes are written to the output buffer, or the
Signature · 1 line
#Randy
#6 lore raw
In reply to Yang Li
Quoted 2 lines · Yang Li

This commit adds kernel-doc style comments with complete parameter descriptions for the function partial_decompress().

This change log doesn't match the subject or the patch.

cheers

Quoted 20 lines
---
 arch/powerpc/boot/decompress.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/powerpc/boot/decompress.c +1 -1
index 977eb15a6d17..6835cb53f034 100644
@@ -101,7 +101,7 @@ static void print_err(char *s)
  * @input_size:  length of the input buffer
  * @outbuf:      output buffer
  * @output_size: length of the output buffer
- * @skip         number of output bytes to ignore
+ * @_skip:       number of output bytes to ignore
  *
  * This function takes compressed data from inbuf, decompresses and write it to
  * outbuf. Once output_size bytes are written to the output buffer, or the
Signature · 1 line
2.20.1.7.g153144c