[PATCH v1 1/1] script: modpost: emit warning when description is missing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Emit a warning when the mod description is missed.

Reported-by: Roland Kletzing <devzero@xxxxxx>
Link: https://bugzilla.kernel.org/show_bug.cgi?id=10770
Signed-off-by: Vincenzo Palazzo <vincenzopalazzodev@xxxxxxxxx>
---
 scripts/mod/modpost.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c
index efff8078e395..c63156ba4e5e 100644
--- a/scripts/mod/modpost.c
+++ b/scripts/mod/modpost.c
@@ -1824,6 +1824,9 @@ static void read_symbols(const char *modname)
 		}
 	}
 
+	if (!get_modinfo(&info, "description"))
+		warn("missing MODULE_DESCRIPTION() in %s\n", modname);
+
 	for (sym = info.symtab_start; sym < info.symtab_stop; sym++) {
 		symname = remove_dot(info.strtab + sym->st_name);
 
-- 
2.39.2




[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux