[PATCH] Add EXPORT_UNUSED_SYMBOL and EXPORT_UNUSED_SYMBOL_GPL
Temporarily add EXPORT_UNUSED_SYMBOL and EXPORT_UNUSED_SYMBOL_GPL. These will be used as a transition measure for symbols that aren't used in the kernel and are on the way out. When a module uses such a symbol, a warning is printk'd at modprobe time. The main reason for removing unused exports is size: eacho export takes roughly between 100 and 150 bytes of kernel space in the binary. This patch gives users the option to immediately get this size gain via a config option. Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
f5e54d6e53
commit
f71d20e961
@ -23,6 +23,22 @@ config MAGIC_SYSRQ
|
||||
keys are documented in <file:Documentation/sysrq.txt>. Don't say Y
|
||||
unless you really know what this hack does.
|
||||
|
||||
config UNUSED_SYMBOLS
|
||||
bool "Enable unused/obsolete exported symbols"
|
||||
default y if X86
|
||||
help
|
||||
Unused but exported symbols make the kernel needlessly bigger. For
|
||||
that reason most of these unused exports will soon be removed. This
|
||||
option is provided temporarily to provide a transition period in case
|
||||
some external kernel module needs one of these symbols anyway. If you
|
||||
encounter such a case in your module, consider if you are actually
|
||||
using the right API. (rationale: since nobody in the kernel is using
|
||||
this in a module, there is a pretty good chance it's actually the
|
||||
wrong interface to use). If you really need the symbol, please send a
|
||||
mail to the linux kernel mailing list mentioning the symbol and why
|
||||
you really need it, and what the merge plan to the mainline kernel for
|
||||
your module is.
|
||||
|
||||
config DEBUG_KERNEL
|
||||
bool "Kernel debugging"
|
||||
help
|
||||
|
Reference in New Issue
Block a user