Skip to content

Commit b9ed847

Browse files
Quentin Perretmasahir0y
authored andcommitted
modpost: turn static exports into error
Using EXPORT_SYMBOL*() on static functions is fundamentally wrong. Modpost currently reports that as a warning, but clearly this is not a pattern we should allow, and all in-tree occurences should have been fixed by now. So, promote the warn() message to error() to make sure this never happens again. Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Matthias Maennich <maennich@google.com> Signed-off-by: Quentin Perret <qperret@google.com> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
1 parent c7299d9 commit b9ed847

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎scripts/mod/modpost.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2648,9 +2648,9 @@ int main(int argc, char **argv)
26482648

26492649
for (s = symbolhash[n]; s; s = s->next) {
26502650
if (s->is_static)
2651-
warn("\"%s\" [%s] is a static %s\n",
2652-
s->name, s->module->name,
2653-
export_str(s->export));
2651+
error("\"%s\" [%s] is a static %s\n",
2652+
s->name, s->module->name,
2653+
export_str(s->export));
26542654
}
26552655
}
26562656

0 commit comments

Comments
 (0)