Skip to contentSkip to conversation

bitops: update MAINTAINERS and fix hweight.c

PATCH Applied Andy Shevchenko 2 participants 4 messages Nov 6, 2025

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover bitops: update MAINTAINERS and fix hweight.c

Update MAINTAINERS and fix hweight.c to avoid kernel-doc warnings.

Andy Shevchenko (2):
bitops: Add missed file to MAINTAINERS
bitops: Update kernel-doc in hweight.c to fix the issues with it

 MAINTAINERS   | 1 +
 lib/hweight.c | 4 ++--
 2 files changed, 3 insertions(+), 2 deletions(-)
Signature · 1 line
2.50.1
#1 lore raw

PATCH 1/2 bitops: Add missed file to MAINTAINERS

In accordance with the history and nature of the operation add lib/hweight.c to the BITOPS record in MAINTAINERS.

---
 MAINTAINERS | 1 +
 1 file changed, 1 insertion(+)
MAINTAINERS +1 -0
index 3d599e8b8b00..a27b48ddfe6c 100644
@@ -4393,6 +4393,7 @@ F:	arch/*/lib/bitops.c
 F:	include/asm-generic/bitops
 F:	include/asm-generic/bitops.h
 F:	include/linux/bitops.h
+F:	lib/hweight.c
 F:	lib/test_bitops.c
 F:	tools/*/bitops*
 
Signature · 1 line
2.50.1
#2 lore raw

PATCH 2/2 bitops: Update kernel-doc in hweight.c to fix the issues with it

In reply to Andy Shevchenko

The kernel-doc in lib/hweight.c is global to the file and currently has issues:

Warning: lib/hweight.c:13 expecting prototype for hweightN(). Prototype was for __sw_hweight32() instead
Warning: lib/hweight.c:13 function parameter 'w' not described in '__sw_hweight32'

Update it accordingly.

---
 lib/hweight.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hweight.c +2 -2
index c94586b62551..0dfcafc3fd39 100644
@@ -4,8 +4,8 @@
 #include <asm/types.h>
 
 /**
- * hweightN - returns the hamming weight of a N-bit word
- * @x: the word to weigh
+ * DOC: __sw_hweightN - returns the hamming weight of a N-bit word
+ * @w: the word to weigh
  *
  * The Hamming Weight of a number is the total number of bits set in it.
  */
Signature · 1 line
2.50.1
maintainer Applied
#3 lore raw
In reply to Andy Shevchenko
Quoted 5 lines · Andy Shevchenko

Update MAINTAINERS and fix hweight.c to avoid kernel-doc warnings.

Andy Shevchenko (2):
bitops: Add missed file to MAINTAINERS
bitops: Update kernel-doc in hweight.c to fix the issues with it

Applied in bitmap-for-next.

Thanks,
Yury