[MODULES]: Don't allow statically declared exports Add an extern declaration for exported symbols to make the compiler warn on symbols declared statically. Signed-off-by: Patrick McHardy --- commit 8648236083e488ff4fc279b66d63b1187e22e558 tree cba9ee372f1056c8cf63cdc6a37a6a761fa490c9 parent 8b21e6d05d6ac0aeb44f5866ab611e2709c2f08e author Patrick McHardy Thu, 23 Mar 2006 05:07:39 +0100 committer Patrick McHardy Thu, 23 Mar 2006 05:07:39 +0100 include/linux/module.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/include/linux/module.h b/include/linux/module.h index 70bd843..d956915 100644 --- a/include/linux/module.h +++ b/include/linux/module.h @@ -183,6 +183,7 @@ void *__symbol_get_gpl(const char *symbo /* For every exported symbol, place a struct in the __ksymtab section */ #define __EXPORT_SYMBOL(sym, sec) \ + extern typeof(sym) sym; \ __CRC_SYMBOL(sym, sec) \ static const char __kstrtab_##sym[] \ __attribute__((section("__ksymtab_strings"))) \