提交 f83ca9fe 编写于 作者: A Andrew Morton 提交者: Linus Torvalds

[PATCH] symversion warning fix

gcc-4.2:

kernel/module.c: In function '__find_symbol':
kernel/module.c:158: warning: the address of '__start___kcrctab', will always evaluate as 'true'
kernel/module.c:165: warning: the address of '__start___kcrctab_gpl', will always evaluate as 'true'
kernel/module.c:182: warning: the address of '__start___kcrctab_gpl_future', will always evaluate as 'true'
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 6d9eac34
...@@ -127,7 +127,7 @@ extern const unsigned long __start___kcrctab_gpl_future[]; ...@@ -127,7 +127,7 @@ extern const unsigned long __start___kcrctab_gpl_future[];
#ifndef CONFIG_MODVERSIONS #ifndef CONFIG_MODVERSIONS
#define symversion(base, idx) NULL #define symversion(base, idx) NULL
#else #else
#define symversion(base, idx) ((base) ? ((base) + (idx)) : NULL) #define symversion(base, idx) ((base != NULL) ? ((base) + (idx)) : NULL)
#endif #endif
/* lookup symbol in given range of kernel_symbols */ /* lookup symbol in given range of kernel_symbols */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册