Skip to contentSkip to conversation

treewide: add missing MODULE_DESCRIPTION() macros

PATCH Applied Jeff Johnson 2 participants 7 messages Jul 30, 2024

Subsystems (10)
Arm (32-bit) x86 PowerPC Arm STM32 +6 more subsystems
lore
Share & tools
lore
#0 lore raw

cover treewide: add missing MODULE_DESCRIPTION() macros

Since commit 1fffe7a34c89 ("script: modpost: emit a warning when the description is missing"), a module without a MODULE_DESCRIPTION() will result in a warning when built with make W=1.

Recently, multiple developers have been eradicating these warnings treewide, and I personally submitted almost 300 patches over the past few months. Almost all of my patches landed by 6.11-rc1, either by being merged in a 6.10-rc or by being merged in the 6.11 merge window. However, a few of my patches did not land.

In some cases I see them in linux-next, but they did not land during the merge window. I'm still monitoring those.

In a few cases I have not had any feedback that the patches have been accepted into a maintainer's tree. At the advice of Greg KH I've consolidated those patches into this single series with the hope these can still land before 6.11-final.
https://lore.kernel.org/all/2024071518-ridden-election-8118 at gregkh/

Links to the original individual patches:

crypto: arm/xor - add missing MODULE_DESCRIPTION() macro
https://lore.kernel.org/all/20240711-md-arm-arch-arm-lib-v2-1-ab08653dc106 at quicinc.com/

x86/mm: add testmmiotrace MODULE_DESCRIPTION()
https://lore.kernel.org/all/20240515-testmmiotrace-md-v1-1-10919a8b2842 at quicinc.com/

cpufreq: powerpc: add missing MODULE_DESCRIPTION() macros
https://lore.kernel.org/all/20240722-md-powerpc-drivers-cpufreq-v2-1-bb84d715eb3d at quicinc.com/

fsi: add missing MODULE_DESCRIPTION() macros
https://lore.kernel.org/all/20240605-md-drivers-fsi-v1-1-fefc82d81b12 at quicinc.com/

locking/ww_mutex/test: add MODULE_DESCRIPTION()
https://lore.kernel.org/all/20240528-md-test-ww_mutex-v2-1-a2a19e920b12 at quicinc.com/

---
Jeff Johnson (5):
crypto: arm/xor - add missing MODULE_DESCRIPTION() macro x86/mm: add testmmiotrace MODULE_DESCRIPTION()
cpufreq: powerpc: add missing MODULE_DESCRIPTION() macros
fsi: add missing MODULE_DESCRIPTION() macros locking/ww_mutex/test: add MODULE_DESCRIPTION()

 arch/arm/lib/xor-neon.c           | 1 +
 arch/x86/mm/testmmiotrace.c       | 1 +
 drivers/cpufreq/maple-cpufreq.c   | 1 +
 drivers/cpufreq/pasemi-cpufreq.c  | 1 +
 drivers/cpufreq/pmac64-cpufreq.c  | 1 +
 drivers/cpufreq/powernv-cpufreq.c | 1 +
 drivers/cpufreq/ppc_cbe_cpufreq.c | 1 +
 drivers/fsi/fsi-core.c            | 1 +
 drivers/fsi/fsi-master-aspeed.c   | 1 +
 drivers/fsi/fsi-master-ast-cf.c   | 3 ++-
 drivers/fsi/fsi-master-gpio.c     | 1 +
 drivers/fsi/fsi-master-hub.c      | 1 +
 drivers/fsi/fsi-scom.c            | 1 +
 kernel/locking/test-ww_mutex.c    | 1 +
 14 files changed, 15 insertions(+), 1 deletion(-)

---
base-commit: 94ede2a3e9135764736221c080ac7c0ad993dc2d
change-id: 20240730-module_description_orphans-cb5e25fe1656

#1 lore raw

PATCH 1/5 crypto: arm/xor - add missing MODULE_DESCRIPTION() macro

With ARCH=arm and CONFIG_KERNEL_MODE_NEON=y, make W=1 C=1 reports:
WARNING: modpost: missing MODULE_DESCRIPTION() in arch/arm/lib/xor-neon.o

Add the missing invocation of the MODULE_DESCRIPTION() macro.

---
 arch/arm/lib/xor-neon.c | 1 +
 1 file changed, 1 insertion(+)
arch/arm/lib/xor-neon.c +1 -0
index 522510baed49..cf57fca97908 100644
@@ -8,6 +8,7 @@
 #include <linux/raid/xor.h>
 #include <linux/module.h>
 
+MODULE_DESCRIPTION("NEON accelerated XOR implementation");
 MODULE_LICENSE("GPL");
 
 #ifndef __ARM_NEON__
Signature · 1 line
2.42.0
#2 lore raw

PATCH 2/5 x86/mm: add testmmiotrace MODULE_DESCRIPTION()

In reply to Jeff Johnson

Fix the following 'make W=1' warning:

WARNING: modpost: missing MODULE_DESCRIPTION() in arch/x86/mm/testmmiotrace.o

---
 arch/x86/mm/testmmiotrace.c | 1 +
 1 file changed, 1 insertion(+)
arch/x86/mm/testmmiotrace.c +1 -0
index bda73cb7a044..ae295659ca14 100644
@@ -144,3 +144,4 @@ static void __exit cleanup(void)
 module_init(init);
 module_exit(cleanup);
 MODULE_LICENSE("GPL");
+MODULE_DESCRIPTION("Test module for mmiotrace");
Signature · 1 line
2.42.0
#3 lore raw

PATCH 3/5 cpufreq: powerpc: add missing MODULE_DESCRIPTION() macros

In reply to Jeff Johnson

With ARCH=powerpc, make allmodconfig && make W=1 C=1 reports:
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/cpufreq/ppc-cbe-cpufreq.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/cpufreq/powernv-cpufreq.o

Add the missing invocation of the MODULE_DESCRIPTION() macro to all files which have a MODULE_LICENSE().

This includes three additional files which, although they did not produce a warning with the powerpc allmodconfig configuration, may cause this warning with specific options enabled in the kernel configuration.

---
 drivers/cpufreq/maple-cpufreq.c   | 1 +
 drivers/cpufreq/pasemi-cpufreq.c  | 1 +
 drivers/cpufreq/pmac64-cpufreq.c  | 1 +
 drivers/cpufreq/powernv-cpufreq.c | 1 +
 drivers/cpufreq/ppc_cbe_cpufreq.c | 1 +
 5 files changed, 5 insertions(+)
drivers/cpufreq/maple-cpufreq.c +1 -0
index f9306410a07f..690da85c4865 100644
@@ -238,4 +238,5 @@ static int __init maple_cpufreq_init(void)
 module_init(maple_cpufreq_init);
 
 
+MODULE_DESCRIPTION("cpufreq driver for Maple 970FX/970MP boards");
 MODULE_LICENSE("GPL");
drivers/cpufreq/pasemi-cpufreq.c +1 -0
index ee925b53b6b9..5fc9cb480516 100644
@@ -269,5 +269,6 @@ static void __exit pas_cpufreq_exit(void)
 module_init(pas_cpufreq_init);
 module_exit(pas_cpufreq_exit);
 
+MODULE_DESCRIPTION("cpufreq driver for PA Semi PWRficient");
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Egor Martovetsky <[email protected]>, Olof Johansson <[email protected]>");
drivers/cpufreq/pmac64-cpufreq.c +1 -0
index 2cd2b06849a2..9d3fe36075f8 100644
@@ -671,4 +671,5 @@ static int __init g5_cpufreq_init(void)
 module_init(g5_cpufreq_init);
 
 
+MODULE_DESCRIPTION("cpufreq driver for SMU & 970FX based G5 Macs");
 MODULE_LICENSE("GPL");
drivers/cpufreq/powernv-cpufreq.c +1 -0
index 50c62929f7ca..bc55723b4d87 100644
@@ -1160,5 +1160,6 @@ static void __exit powernv_cpufreq_exit(void)
 }
 module_exit(powernv_cpufreq_exit);
 
+MODULE_DESCRIPTION("cpufreq driver for IBM/OpenPOWER powernv systems");
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Vaidyanathan Srinivasan <[email protected]>");
drivers/cpufreq/ppc_cbe_cpufreq.c +1 -0
index 5ee4c7bfdcc5..98595b3ea13f 100644
@@ -168,5 +168,6 @@ static void __exit cbe_cpufreq_exit(void)
 module_init(cbe_cpufreq_init);
 module_exit(cbe_cpufreq_exit);
 
+MODULE_DESCRIPTION("cpufreq driver for Cell BE processors");
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Christian Krafft <[email protected]>");
Signature · 1 line
2.42.0
#4 lore raw

PATCH 4/5 fsi: add missing MODULE_DESCRIPTION() macros

In reply to Jeff Johnson

make allmodconfig && make W=1 C=1 reports:
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-core.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-hub.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-aspeed.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-gpio.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-master-ast-cf.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/fsi/fsi-scom.o

Add the missing invocations of the MODULE_DESCRIPTION() macro, and fix the copy/paste of the module description comment in fsi-master-ast-cf.c.

---
 drivers/fsi/fsi-core.c          | 1 +
 drivers/fsi/fsi-master-aspeed.c | 1 +
 drivers/fsi/fsi-master-ast-cf.c | 3 ++-
 drivers/fsi/fsi-master-gpio.c   | 1 +
 drivers/fsi/fsi-master-hub.c    | 1 +
 drivers/fsi/fsi-scom.c          | 1 +
 6 files changed, 7 insertions(+), 1 deletion(-)
drivers/fsi/fsi-core.c +1 -0
index 46ac5a8beab7..e2e1e9df6115 100644
@@ -1444,5 +1444,6 @@ static void fsi_exit(void)
 }
 module_exit(fsi_exit);
 module_param(discard_errors, int, 0664);
+MODULE_DESCRIPTION("FSI core driver");
 MODULE_LICENSE("GPL");
 MODULE_PARM_DESC(discard_errors, "Don't invoke error handling on bus accesses");
drivers/fsi/fsi-master-aspeed.c +1 -0
index b0b624c3717b..6f5e1bdf7e40 100644
@@ -670,4 +670,5 @@ static struct platform_driver fsi_master_aspeed_driver = {
 };
 
 module_platform_driver(fsi_master_aspeed_driver);
+MODULE_DESCRIPTION("FSI master driver for AST2600");
 MODULE_LICENSE("GPL");
drivers/fsi/fsi-master-ast-cf.c +2 -1
index f8c776ce1b56..a4c37ff8edd6 100644
@@ -1,7 +1,7 @@
 // SPDX-License-Identifier: GPL-2.0+
 // Copyright 2018 IBM Corp
 /*
- * A FSI master controller, using a simple GPIO bit-banging interface
+ * A FSI master based on Aspeed ColdFire coprocessor
  */
 
 #include <linux/crc4.h>
@@ -1438,5 +1438,6 @@ static struct platform_driver fsi_master_acf = {
 };
 
 module_platform_driver(fsi_master_acf);
+MODULE_DESCRIPTION("A FSI master based on Aspeed ColdFire coprocessor");
 MODULE_LICENSE("GPL");
 MODULE_FIRMWARE(FW_FILE_NAME);
drivers/fsi/fsi-master-gpio.c +1 -0
index 10fc344b6b22..f761344f4873 100644
@@ -892,4 +892,5 @@ static struct platform_driver fsi_master_gpio_driver = {
 };
 
 module_platform_driver(fsi_master_gpio_driver);
+MODULE_DESCRIPTION("A FSI master controller, using a simple GPIO bit-banging interface");
 MODULE_LICENSE("GPL");
drivers/fsi/fsi-master-hub.c +1 -0
index 6d8b6e8854e5..6568fed7db3c 100644
@@ -295,4 +295,5 @@ static struct fsi_driver hub_master_driver = {
 };
 
 module_fsi_driver(hub_master_driver);
+MODULE_DESCRIPTION("FSI hub master driver");
 MODULE_LICENSE("GPL");
drivers/fsi/fsi-scom.c +1 -0
index 61dbda9dbe2b..411ddc018cd8 100644
@@ -625,4 +625,5 @@ static void scom_exit(void)
 
 module_init(scom_init);
 module_exit(scom_exit);
+MODULE_DESCRIPTION("SCOM FSI Client device driver");
 MODULE_LICENSE("GPL");
Signature · 1 line
2.42.0
#5 lore raw

PATCH 5/5 locking/ww_mutex/test: add MODULE_DESCRIPTION()

In reply to Jeff Johnson

Fix the 'make W=1' warning:
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/locking/test-ww_mutex.o

---
 kernel/locking/test-ww_mutex.c | 1 +
 1 file changed, 1 insertion(+)
kernel/locking/test-ww_mutex.c +1 -0
index 78719e1ef1b1..10a5736a21c2 100644
@@ -697,3 +697,4 @@ module_exit(test_ww_mutex_exit);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Intel Corporation");
+MODULE_DESCRIPTION("API test facility for ww_mutexes");
Signature · 1 line
2.42.0
reviewer Acked-by on v1 5/5
#6 lore raw

Re: [PATCH 5/5] locking/ww_mutex/test: add MODULE_DESCRIPTION()

Quoted 13 lines · Jeff Johnson

Fix the 'make W=1' warning:
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/locking/test-ww_mutex.o

---
  kernel/locking/test-ww_mutex.c | 1 +
  1 file changed, 1 insertion(+)
kernel/locking/test-ww_mutex.c +0 -0
index 78719e1ef1b1..10a5736a21c2 100644

kernel/locking/test-ww_mutex.c module_exit(test_ww_mutex_exit); · line 700

Quoted 4 lines
kernel/locking/test-ww_mutex.c +1 -0
@@ -697,3 +697,4 @@ module_exit(test_ww_mutex_exit);
 
  MODULE_LICENSE("GPL");
  MODULE_AUTHOR("Intel Corporation");
+MODULE_DESCRIPTION("API test facility for ww_mutexes");