History

modpost: do not warn about missing MODULE_DESCRIPTION() for vmlinux.o

Building with W=1 incorrectly emits the following warning: WARNING: modpost: missing MODULE_DESCRIPTION() in vmlinux.o This check should apply only to modules.

Masahiro Yamada committed 2 years ago

Commit 9185afe1 parent 96c96561 file · +3 −2Browse files

Showing the changes to scripts (1 of 1 file). Show all

Unified · Split

scripts/mod/modpost.c+3−2
@@ -1647,10 +1647,11 @@ static void read_symbols(const char *modname) · 1646 unmodified lines
16471647 namespace = get_next_modinfo(&info, "import_ns",
16481648 namespace);
16491649 }
1650+
1651+ if (extra_warn && !get_modinfo(&info, "description"))
1652+ warn("missing MODULE_DESCRIPTION() in %s\n", modname);
16501653 }
16511654
1652− if (extra_warn && !get_modinfo(&info, "description"))
1653− warn("missing MODULE_DESCRIPTION() in %s\n", modname);
16541655 for (sym = info.symtab_start; sym < info.symtab_stop; sym++) {
16551656 symname = remove_dot(info.strtab + sym->st_name);
16561657