X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=init%2FKconfig;h=f755a602d4a176e006dc2cb5830d1c4812bac81f;hb=3522b35cb2e2e24e03edf112e6466f3a626918a9;hp=a9c4aefd5436edf12d6bda5ab775fbee3e7a8fd8;hpb=08344f3b43a6bfaf2926122cef44d9a9583c2a4e;p=deliverable%2Flinux.git diff --git a/init/Kconfig b/init/Kconfig index a9c4aefd5436..f755a602d4a1 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -1306,6 +1306,17 @@ source "usr/Kconfig" endif +choice + prompt "Compiler optimization level" + default CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE + +config CC_OPTIMIZE_FOR_PERFORMANCE + bool "Optimize for performance" + help + This is the default optimization level for the kernel, building + with the "-O2" compiler flag for best performance and most + helpful compile-time warnings. + config CC_OPTIMIZE_FOR_SIZE bool "Optimize for size" help @@ -1314,6 +1325,8 @@ config CC_OPTIMIZE_FOR_SIZE If unsure, say N. +endchoice + config SYSCTL bool @@ -2049,6 +2062,22 @@ config MODULE_COMPRESS_XZ endchoice +config TRIM_UNUSED_KSYMS + bool "Trim unused exported kernel symbols" + depends on MODULES && !UNUSED_SYMBOLS + help + The kernel and some modules make many symbols available for + other modules to use via EXPORT_SYMBOL() and variants. Depending + on the set of modules being selected in your kernel configuration, + many of those exported symbols might never be used. + + This option allows for unused exported symbols to be dropped from + the build. In turn, this provides the compiler more opportunities + (especially when using LTO) for optimizing the code and reducing + binary size. This might have some security advantages as well. + + If unsure say N. + endif # MODULES config MODULES_TREE_LOOKUP