1
0

Config-kernel.in 39 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356
  1. # SPDX-License-Identifier: GPL-2.0-only
  2. #
  3. # Copyright (C) 2006-2014 OpenWrt.org
  4. config KERNEL_BUILD_USER
  5. string "Custom Kernel Build User Name"
  6. default "builder" if BUILDBOT
  7. default ""
  8. help
  9. Sets the Kernel build user string, which for example will be returned
  10. by 'uname -a' on running systems.
  11. If not set, uses system user at build time.
  12. config KERNEL_BUILD_DOMAIN
  13. string "Custom Kernel Build Domain Name"
  14. default "buildhost" if BUILDBOT
  15. default ""
  16. help
  17. Sets the Kernel build domain string, which for example will be
  18. returned by 'uname -a' on running systems.
  19. If not set, uses system hostname at build time.
  20. config KERNEL_PRINTK
  21. bool "Enable support for printk"
  22. default y
  23. config KERNEL_SWAP
  24. bool "Support for paging of anonymous memory (swap)"
  25. default y if !SMALL_FLASH
  26. config KERNEL_PROC_STRIPPED
  27. bool "Strip non-essential /proc functionality to reduce code size"
  28. default y if SMALL_FLASH
  29. config KERNEL_DEBUG_FS
  30. bool "Compile the kernel with debug filesystem enabled"
  31. default y
  32. help
  33. debugfs is a virtual file system that kernel developers use to put
  34. debugging files into. Enable this option to be able to read and
  35. write to these files. Many common debugging facilities, such as
  36. ftrace, require the existence of debugfs.
  37. config KERNEL_MIPS_FP_SUPPORT
  38. bool
  39. default y if TARGET_pistachio
  40. config KERNEL_ARM_PMU
  41. bool
  42. default y if TARGET_armsr_armv8
  43. depends on (arm || aarch64)
  44. config KERNEL_X86_VSYSCALL_EMULATION
  45. bool "Enable vsyscall emulation"
  46. depends on x86_64
  47. help
  48. This enables emulation of the legacy vsyscall page. Disabling
  49. it is roughly equivalent to booting with vsyscall=none, except
  50. that it will also disable the helpful warning if a program
  51. tries to use a vsyscall. With this option set to N, offending
  52. programs will just segfault, citing addresses of the form
  53. 0xffffffffff600?00.
  54. This option is required by many programs built before 2013, and
  55. care should be used even with newer programs if set to N.
  56. Disabling this option saves about 7K of kernel size and
  57. possibly 4K of additional runtime pagetable memory.
  58. config KERNEL_PERF_EVENTS
  59. bool "Compile the kernel with performance events and counters"
  60. select KERNEL_ARM_PMU if (arm || aarch64)
  61. config KERNEL_PROFILING
  62. bool "Compile the kernel with profiling enabled"
  63. select KERNEL_PERF_EVENTS
  64. help
  65. Enable the extended profiling support mechanisms used by profilers such
  66. as OProfile.
  67. config KERNEL_RPI_AXIPERF
  68. bool "Compile the kernel with RaspberryPi AXI Performance monitors"
  69. default y
  70. depends on KERNEL_PERF_EVENTS && TARGET_bcm27xx
  71. config KERNEL_UBSAN
  72. bool "Compile the kernel with undefined behaviour sanity checker"
  73. help
  74. This option enables undefined behaviour sanity checker
  75. Compile-time instrumentation is used to detect various undefined
  76. behaviours in runtime. Various types of checks may be enabled
  77. via boot parameter ubsan_handle
  78. (see: Documentation/dev-tools/ubsan.rst).
  79. config KERNEL_UBSAN_SANITIZE_ALL
  80. bool "Enable instrumentation for the entire kernel"
  81. depends on KERNEL_UBSAN
  82. default y
  83. help
  84. This option activates instrumentation for the entire kernel.
  85. If you don't enable this option, you have to explicitly specify
  86. UBSAN_SANITIZE := y for the files/directories you want to check for UB.
  87. Enabling this option will get kernel image size increased
  88. significantly.
  89. config KERNEL_UBSAN_ALIGNMENT
  90. bool "Enable checking of pointers alignment"
  91. depends on KERNEL_UBSAN
  92. help
  93. This option enables detection of unaligned memory accesses.
  94. Enabling this option on architectures that support unaligned
  95. accesses may produce a lot of false positives.
  96. config KERNEL_UBSAN_BOUNDS
  97. bool "Perform array index bounds checking"
  98. depends on KERNEL_UBSAN
  99. help
  100. This option enables detection of directly indexed out of bounds array
  101. accesses, where the array size is known at compile time. Note that
  102. this does not protect array overflows via bad calls to the
  103. {str,mem}*cpy() family of functions (that is addressed by
  104. FORTIFY_SOURCE).
  105. config KERNEL_UBSAN_NULL
  106. bool "Enable checking of null pointers"
  107. depends on KERNEL_UBSAN
  108. help
  109. This option enables detection of memory accesses via a
  110. null pointer.
  111. config KERNEL_UBSAN_TRAP
  112. bool "On Sanitizer warnings, abort the running kernel code"
  113. depends on KERNEL_UBSAN
  114. help
  115. Building kernels with Sanitizer features enabled tends to grow the
  116. kernel size by around 5%, due to adding all the debugging text on
  117. failure paths. To avoid this, Sanitizer instrumentation can just
  118. issue a trap. This reduces the kernel size overhead but turns all
  119. warnings (including potentially harmless conditions) into full
  120. exceptions that abort the running kernel code (regardless of context,
  121. locks held, etc), which may destabilize the system. For some system
  122. builders this is an acceptable trade-off.
  123. config KERNEL_KASAN
  124. bool "Compile the kernel with KASan: runtime memory debugger"
  125. select KERNEL_SLUB_DEBUG
  126. depends on (x86_64 || aarch64)
  127. help
  128. Enables kernel address sanitizer - runtime memory debugger,
  129. designed to find out-of-bounds accesses and use-after-free bugs.
  130. This is strictly a debugging feature and it requires a gcc version
  131. of 4.9.2 or later. Detection of out of bounds accesses to stack or
  132. global variables requires gcc 5.0 or later.
  133. This feature consumes about 1/8 of available memory and brings about
  134. ~x3 performance slowdown.
  135. For better error detection enable CONFIG_STACKTRACE.
  136. Currently CONFIG_KASAN doesn't work with CONFIG_DEBUG_SLAB
  137. (the resulting kernel does not boot).
  138. config KERNEL_KASAN_EXTRA
  139. bool "KAsan: extra checks"
  140. depends on KERNEL_KASAN && KERNEL_DEBUG_KERNEL
  141. help
  142. This enables further checks in the kernel address sanitizer, for now
  143. it only includes the address-use-after-scope check that can lead
  144. to excessive kernel stack usage, frame size warnings and longer
  145. compile time.
  146. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81715 has more
  147. config KERNEL_KASAN_VMALLOC
  148. bool "Back mappings in vmalloc space with real shadow memory"
  149. depends on KERNEL_KASAN
  150. help
  151. By default, the shadow region for vmalloc space is the read-only
  152. zero page. This means that KASAN cannot detect errors involving
  153. vmalloc space.
  154. Enabling this option will hook in to vmap/vmalloc and back those
  155. mappings with real shadow memory allocated on demand. This allows
  156. for KASAN to detect more sorts of errors (and to support vmapped
  157. stacks), but at the cost of higher memory usage.
  158. This option depends on HAVE_ARCH_KASAN_VMALLOC, but we can't
  159. depend on that in here, so it is possible that enabling this
  160. will have no effect.
  161. if KERNEL_KASAN
  162. config KERNEL_KASAN_GENERIC
  163. def_bool y
  164. config KERNEL_KASAN_SW_TAGS
  165. def_bool n
  166. endif
  167. choice
  168. prompt "Instrumentation type"
  169. depends on KERNEL_KASAN
  170. default KERNEL_KASAN_OUTLINE
  171. config KERNEL_KASAN_OUTLINE
  172. bool "Outline instrumentation"
  173. help
  174. Before every memory access compiler insert function call
  175. __asan_load*/__asan_store*. These functions performs check
  176. of shadow memory. This is slower than inline instrumentation,
  177. however it doesn't bloat size of kernel's .text section so
  178. much as inline does.
  179. config KERNEL_KASAN_INLINE
  180. bool "Inline instrumentation"
  181. help
  182. Compiler directly inserts code checking shadow memory before
  183. memory accesses. This is faster than outline (in some workloads
  184. it gives about x2 boost over outline instrumentation), but
  185. make kernel's .text size much bigger.
  186. This requires a gcc version of 5.0 or later.
  187. endchoice
  188. config KERNEL_KCOV
  189. bool "Compile the kernel with code coverage for fuzzing"
  190. select KERNEL_DEBUG_FS
  191. help
  192. KCOV exposes kernel code coverage information in a form suitable
  193. for coverage-guided fuzzing (randomized testing).
  194. If RANDOMIZE_BASE is enabled, PC values will not be stable across
  195. different machines and across reboots. If you need stable PC values,
  196. disable RANDOMIZE_BASE.
  197. For more details, see Documentation/kcov.txt.
  198. config KERNEL_KCOV_ENABLE_COMPARISONS
  199. bool "Enable comparison operands collection by KCOV"
  200. depends on KERNEL_KCOV
  201. help
  202. KCOV also exposes operands of every comparison in the instrumented
  203. code along with operand sizes and PCs of the comparison instructions.
  204. These operands can be used by fuzzing engines to improve the quality
  205. of fuzzing coverage.
  206. config KERNEL_KCOV_INSTRUMENT_ALL
  207. bool "Instrument all code by default"
  208. depends on KERNEL_KCOV
  209. default y if KERNEL_KCOV
  210. help
  211. If you are doing generic system call fuzzing (like e.g. syzkaller),
  212. then you will want to instrument the whole kernel and you should
  213. say y here. If you are doing more targeted fuzzing (like e.g.
  214. filesystem fuzzing with AFL) then you will want to enable coverage
  215. for more specific subsets of files, and should say n here.
  216. config KERNEL_TASKSTATS
  217. bool "Compile the kernel with task resource/io statistics and accounting"
  218. help
  219. Enable the collection and publishing of task/io statistics and
  220. accounting. Enable this option to enable i/o monitoring in system
  221. monitors.
  222. if KERNEL_TASKSTATS
  223. config KERNEL_TASK_DELAY_ACCT
  224. def_bool y
  225. config KERNEL_TASK_IO_ACCOUNTING
  226. def_bool y
  227. config KERNEL_TASK_XACCT
  228. def_bool y
  229. endif
  230. config KERNEL_KALLSYMS
  231. bool "Compile the kernel with symbol table information"
  232. default y if !SMALL_FLASH
  233. help
  234. This will give you more information in stack traces from kernel oopses.
  235. config KERNEL_FTRACE
  236. bool "Compile the kernel with tracing support"
  237. depends on !TARGET_uml
  238. config KERNEL_FTRACE_SYSCALLS
  239. bool "Trace system calls"
  240. depends on KERNEL_FTRACE
  241. config KERNEL_ENABLE_DEFAULT_TRACERS
  242. bool "Trace process context switches and events"
  243. depends on KERNEL_FTRACE
  244. config KERNEL_FUNCTION_TRACER
  245. bool "Function tracer"
  246. depends on KERNEL_FTRACE
  247. config KERNEL_FUNCTION_GRAPH_TRACER
  248. bool "Function graph tracer"
  249. depends on KERNEL_FUNCTION_TRACER
  250. config KERNEL_DYNAMIC_FTRACE
  251. bool "Enable/disable function tracing dynamically"
  252. depends on KERNEL_FUNCTION_TRACER
  253. config KERNEL_FUNCTION_PROFILER
  254. bool "Function profiler"
  255. depends on KERNEL_FUNCTION_TRACER
  256. config KERNEL_IRQSOFF_TRACER
  257. bool "Interrupts-off Latency Tracer"
  258. depends on KERNEL_FTRACE
  259. help
  260. This option measures the time spent in irqs-off critical
  261. sections, with microsecond accuracy.
  262. The default measurement method is a maximum search, which is
  263. disabled by default and can be runtime (re-)started
  264. via:
  265. echo 0 > /sys/kernel/debug/tracing/tracing_max_latency
  266. (Note that kernel size and overhead increase with this option
  267. enabled. This option and the preempt-off timing option can be
  268. used together or separately.)
  269. config KERNEL_PREEMPT_TRACER
  270. bool "Preemption-off Latency Tracer"
  271. depends on KERNEL_FTRACE
  272. help
  273. This option measures the time spent in preemption-off critical
  274. sections, with microsecond accuracy.
  275. The default measurement method is a maximum search, which is
  276. disabled by default and can be runtime (re-)started
  277. via:
  278. echo 0 > /sys/kernel/debug/tracing/tracing_max_latency
  279. (Note that kernel size and overhead increase with this option
  280. enabled. This option and the irqs-off timing option can be
  281. used together or separately.)
  282. config KERNEL_HIST_TRIGGERS
  283. bool "Histogram triggers"
  284. depends on KERNEL_FTRACE
  285. help
  286. Hist triggers allow one or more arbitrary trace event fields to be
  287. aggregated into hash tables and dumped to stdout by reading a
  288. debugfs/tracefs file. They're useful for gathering quick and dirty
  289. (though precise) summaries of event activity as an initial guide for
  290. further investigation using more advanced tools.
  291. Inter-event tracing of quantities such as latencies is also
  292. supported using hist triggers under this option.
  293. config KERNEL_DEBUG_KERNEL
  294. bool
  295. config KERNEL_DEBUG_INFO
  296. bool "Compile the kernel with debug information"
  297. default y if !SMALL_FLASH
  298. select KERNEL_DEBUG_KERNEL
  299. help
  300. This will compile your kernel and modules with debug information.
  301. config KERNEL_DEBUG_INFO_BTF
  302. bool "Enable additional BTF type information"
  303. depends on !HOST_OS_MACOS
  304. depends on KERNEL_DEBUG_INFO && !KERNEL_DEBUG_INFO_REDUCED
  305. select DWARVES
  306. help
  307. Generate BPF Type Format (BTF) information from DWARF debug info.
  308. Turning this on expects presence of pahole tool, which will convert
  309. DWARF type info into equivalent deduplicated BTF type info.
  310. Required to run BPF CO-RE applications.
  311. config KERNEL_DEBUG_INFO_REDUCED
  312. bool "Reduce debugging information"
  313. default y
  314. depends on KERNEL_DEBUG_INFO
  315. help
  316. If you say Y here gcc is instructed to generate less debugging
  317. information for structure types. This means that tools that
  318. need full debugging information (like kgdb or systemtap) won't
  319. be happy. But if you merely need debugging information to
  320. resolve line numbers there is no loss. Advantage is that
  321. build directory object sizes shrink dramatically over a full
  322. DEBUG_INFO build and compile times are reduced too.
  323. Only works with newer gcc versions.
  324. config KERNEL_FRAME_WARN
  325. int
  326. range 0 8192
  327. default 1280 if KERNEL_KASAN && !ARCH_64BIT
  328. default 1024 if !ARCH_64BIT
  329. default 2048 if ARCH_64BIT
  330. help
  331. Tell the compiler to warn at build time for stack frames larger than this.
  332. Setting this too low will cause a lot of warnings.
  333. Setting it to 0 disables the warning.
  334. # KERNEL_DEBUG_LL symbols must have the default value set as otherwise
  335. # KConfig wont evaluate them unless KERNEL_EARLY_PRINTK is selected
  336. # which means that buildroot wont override the DEBUG_LL symbols in target
  337. # kernel configurations and lead to devices that dont have working console
  338. config KERNEL_DEBUG_LL_UART_NONE
  339. bool
  340. default n
  341. depends on arm
  342. config KERNEL_DEBUG_LL
  343. bool
  344. default n
  345. depends on arm
  346. select KERNEL_DEBUG_LL_UART_NONE
  347. help
  348. ARM low level debugging.
  349. config KERNEL_DEBUG_VIRTUAL
  350. bool "Compile the kernel with VM translations debugging"
  351. select KERNEL_DEBUG_KERNEL
  352. help
  353. Enable checks sanity checks to catch invalid uses of
  354. virt_to_phys()/phys_to_virt() against the non-linear address space.
  355. config KERNEL_DYNAMIC_DEBUG
  356. bool "Compile the kernel with dynamic printk"
  357. select KERNEL_DEBUG_FS
  358. help
  359. Compiles debug level messages into the kernel, which would not
  360. otherwise be available at runtime. These messages can then be
  361. enabled/disabled based on various levels of scope - per source file,
  362. function, module, format string, and line number. This mechanism
  363. implicitly compiles in all pr_debug() and dev_dbg() calls, which
  364. enlarges the kernel text size by about 2%.
  365. config KERNEL_EARLY_PRINTK
  366. bool "Compile the kernel with early printk"
  367. default y if TARGET_bcm53xx
  368. depends on arm
  369. select KERNEL_DEBUG_KERNEL
  370. select KERNEL_DEBUG_LL if arm
  371. help
  372. Compile the kernel with early printk support. This is only useful for
  373. debugging purposes to send messages over the serial console in early boot.
  374. Enable this to debug early boot problems.
  375. config KERNEL_KPROBES
  376. bool "Compile the kernel with kprobes support"
  377. select KERNEL_FTRACE
  378. select KERNEL_PERF_EVENTS
  379. help
  380. Compiles the kernel with KPROBES support, which allows you to trap
  381. at almost any kernel address and execute a callback function.
  382. register_kprobe() establishes a probepoint and specifies the
  383. callback. Kprobes is useful for kernel debugging, non-intrusive
  384. instrumentation and testing.
  385. If in doubt, say "N".
  386. config KERNEL_KPROBE_EVENTS
  387. bool
  388. default y if KERNEL_KPROBES
  389. config KERNEL_BPF_EVENTS
  390. bool "Compile the kernel with BPF event support"
  391. select KERNEL_KPROBES
  392. help
  393. Allows to attach BPF programs to kprobe, uprobe and tracepoint events.
  394. This is required to use BPF maps of type BPF_MAP_TYPE_PERF_EVENT_ARRAY
  395. for sending data from BPF programs to user-space for post-processing
  396. or logging.
  397. config KERNEL_BPF_KPROBE_OVERRIDE
  398. bool
  399. depends on KERNEL_KPROBES
  400. default n
  401. config KERNEL_AIO
  402. bool "Compile the kernel with asynchronous IO support"
  403. default y if !SMALL_FLASH
  404. config KERNEL_IO_URING
  405. bool "Compile the kernel with io_uring support"
  406. depends on !SMALL_FLASH
  407. default y if (x86_64 || aarch64)
  408. config KERNEL_FHANDLE
  409. bool "Compile the kernel with support for fhandle syscalls"
  410. default y if !SMALL_FLASH
  411. config KERNEL_FANOTIFY
  412. bool "Compile the kernel with modern file notification support"
  413. default y if !SMALL_FLASH
  414. config KERNEL_BLK_DEV_BSG
  415. bool "Compile the kernel with SCSI generic v4 support for any block device"
  416. config KERNEL_TRANSPARENT_HUGEPAGE
  417. bool
  418. choice
  419. prompt "Transparent Hugepage Support sysfs defaults"
  420. depends on KERNEL_TRANSPARENT_HUGEPAGE
  421. default KERNEL_TRANSPARENT_HUGEPAGE_ALWAYS
  422. config KERNEL_TRANSPARENT_HUGEPAGE_ALWAYS
  423. bool "always"
  424. config KERNEL_TRANSPARENT_HUGEPAGE_MADVISE
  425. bool "madvise"
  426. endchoice
  427. config KERNEL_HUGETLBFS
  428. bool
  429. config KERNEL_HUGETLB_PAGE
  430. bool "Compile the kernel with HugeTLB support"
  431. select KERNEL_TRANSPARENT_HUGEPAGE
  432. select KERNEL_HUGETLBFS
  433. config KERNEL_MAGIC_SYSRQ
  434. bool "Compile the kernel with SysRq support"
  435. default y
  436. config KERNEL_DEBUG_PINCTRL
  437. bool "Compile the kernel with pinctrl debugging"
  438. select KERNEL_DEBUG_KERNEL
  439. config KERNEL_DEBUG_GPIO
  440. bool "Compile the kernel with gpio debugging"
  441. select KERNEL_DEBUG_KERNEL
  442. config KERNEL_COREDUMP
  443. bool
  444. config KERNEL_ELF_CORE
  445. bool "Enable process core dump support"
  446. select KERNEL_COREDUMP
  447. default y if !SMALL_FLASH
  448. config KERNEL_PROVE_LOCKING
  449. bool "Enable kernel lock checking"
  450. select KERNEL_DEBUG_KERNEL
  451. config KERNEL_SOFTLOCKUP_DETECTOR
  452. bool "Compile the kernel with detect Soft Lockups"
  453. depends on KERNEL_DEBUG_KERNEL
  454. help
  455. Say Y here to enable the kernel to act as a watchdog to detect
  456. soft lockups.
  457. Softlockups are bugs that cause the kernel to loop in kernel
  458. mode for more than 20 seconds, without giving other tasks a
  459. chance to run. The current stack trace is displayed upon
  460. detection and the system will stay locked up.
  461. config KERNEL_HARDLOCKUP_DETECTOR
  462. bool "Compile the kernel with detect Hard Lockups"
  463. depends on KERNEL_DEBUG_KERNEL
  464. help
  465. Say Y here to enable the kernel to act as a watchdog to detect
  466. hard lockups.
  467. Hardlockups are bugs that cause the CPU to loop in kernel mode
  468. for more than 10 seconds, without letting other interrupts have a
  469. chance to run. The current stack trace is displayed upon detection
  470. and the system will stay locked up.
  471. config KERNEL_DETECT_HUNG_TASK
  472. bool "Compile the kernel with detect Hung Tasks"
  473. depends on KERNEL_DEBUG_KERNEL
  474. default KERNEL_SOFTLOCKUP_DETECTOR
  475. help
  476. Say Y here to enable the kernel to detect "hung tasks",
  477. which are bugs that cause the task to be stuck in
  478. uninterruptible "D" state indefinitely.
  479. When a hung task is detected, the kernel will print the
  480. current stack trace (which you should report), but the
  481. task will stay in uninterruptible state. If lockdep is
  482. enabled then all held locks will also be reported. This
  483. feature has negligible overhead.
  484. config KERNEL_WQ_WATCHDOG
  485. bool "Compile the kernel with detect Workqueue Stalls"
  486. depends on KERNEL_DEBUG_KERNEL
  487. help
  488. Say Y here to enable stall detection on workqueues. If a
  489. worker pool doesn't make forward progress on a pending work
  490. item for over a given amount of time, 30s by default, a
  491. warning message is printed along with dump of workqueue
  492. state. This can be configured through kernel parameter
  493. "workqueue.watchdog_thresh" and its sysfs counterpart.
  494. config KERNEL_DEBUG_ATOMIC_SLEEP
  495. bool "Compile the kernel with sleep inside atomic section checking"
  496. depends on KERNEL_DEBUG_KERNEL
  497. help
  498. If you say Y here, various routines which may sleep will become very
  499. noisy if they are called inside atomic sections: when a spinlock is
  500. held, inside an rcu read side critical section, inside preempt disabled
  501. sections, inside an interrupt, etc...
  502. config KERNEL_DEBUG_VM
  503. bool "Compile the kernel with debug VM"
  504. depends on KERNEL_DEBUG_KERNEL
  505. help
  506. Enable this to turn on extended checks in the virtual-memory system
  507. that may impact performance.
  508. If unsure, say N.
  509. config KERNEL_PRINTK_TIME
  510. bool "Enable printk timestamps"
  511. default y
  512. config KERNEL_SLUB_DEBUG
  513. bool
  514. config KERNEL_SLUB_DEBUG_ON
  515. bool
  516. config KERNEL_SLABINFO
  517. select KERNEL_SLUB_DEBUG
  518. select KERNEL_SLUB_DEBUG_ON
  519. bool "Enable /proc slab debug info"
  520. config KERNEL_PROC_PAGE_MONITOR
  521. bool "Enable /proc page monitoring"
  522. config KERNEL_RELAY
  523. bool
  524. config KERNEL_KEXEC
  525. bool "Enable kexec support"
  526. config KERNEL_PROC_VMCORE
  527. bool
  528. config KERNEL_PROC_KCORE
  529. bool
  530. config KERNEL_CRASH_DUMP
  531. depends on i386 || x86_64 || arm || armeb
  532. select KERNEL_KEXEC
  533. select KERNEL_PROC_VMCORE
  534. select KERNEL_PROC_KCORE
  535. bool "Enable support for kexec crashdump"
  536. default y
  537. config USE_RFKILL
  538. bool "Enable rfkill support"
  539. default RFKILL_SUPPORT
  540. config USE_SPARSE
  541. bool "Enable sparse check during kernel build"
  542. config KERNEL_DEVTMPFS
  543. bool "Compile the kernel with device tmpfs enabled"
  544. help
  545. devtmpfs is a simple, kernel-managed /dev filesystem. The kernel creates
  546. devices nodes for all registered devices to simplify boot, but leaves more
  547. complex tasks to userspace (e.g. udev).
  548. if KERNEL_DEVTMPFS
  549. config KERNEL_DEVTMPFS_MOUNT
  550. bool "Automatically mount devtmpfs after root filesystem is mounted"
  551. endif
  552. config KERNEL_KEYS
  553. bool "Enable kernel access key retention support"
  554. default !SMALL_FLASH
  555. config KERNEL_PERSISTENT_KEYRINGS
  556. bool "Enable kernel persistent keyrings"
  557. depends on KERNEL_KEYS
  558. config KERNEL_KEYS_REQUEST_CACHE
  559. bool "Enable temporary caching of the last request_key() result"
  560. depends on KERNEL_KEYS
  561. config KERNEL_BIG_KEYS
  562. bool "Enable large payload keys on kernel keyrings"
  563. depends on KERNEL_KEYS
  564. #
  565. # CGROUP support symbols
  566. #
  567. config KERNEL_CGROUPS
  568. bool "Enable kernel cgroups"
  569. default y if !SMALL_FLASH
  570. if KERNEL_CGROUPS
  571. config KERNEL_CGROUP_DEBUG
  572. bool "Example debug cgroup subsystem"
  573. help
  574. This option enables a simple cgroup subsystem that
  575. exports useful debugging information about the cgroups
  576. framework.
  577. config KERNEL_FREEZER
  578. bool
  579. config KERNEL_CGROUP_FREEZER
  580. bool "legacy Freezer cgroup subsystem"
  581. select KERNEL_FREEZER
  582. help
  583. Provides a way to freeze and unfreeze all tasks in a
  584. cgroup.
  585. (legacy cgroup1-only controller, in cgroup2 freezer
  586. is integrated in the Memory controller)
  587. config KERNEL_CGROUP_DEVICE
  588. bool "legacy Device controller for cgroups"
  589. help
  590. Provides a cgroup implementing whitelists for devices which
  591. a process in the cgroup can mknod or open.
  592. (legacy cgroup1-only controller)
  593. config KERNEL_CGROUP_HUGETLB
  594. bool "HugeTLB controller"
  595. select KERNEL_HUGETLB_PAGE
  596. config KERNEL_CGROUP_PIDS
  597. bool "PIDs cgroup subsystem"
  598. default y
  599. help
  600. Provides enforcement of process number limits in the scope of a
  601. cgroup.
  602. config KERNEL_CGROUP_RDMA
  603. bool "RDMA controller for cgroups"
  604. default y
  605. config KERNEL_CGROUP_BPF
  606. bool "Support for eBPF programs attached to cgroups"
  607. default y
  608. config KERNEL_CPUSETS
  609. bool "Cpuset support"
  610. default y
  611. help
  612. This option will let you create and manage CPUSETs which
  613. allow dynamically partitioning a system into sets of CPUs and
  614. Memory Nodes and assigning tasks to run only within those sets.
  615. This is primarily useful on large SMP or NUMA systems.
  616. config KERNEL_PROC_PID_CPUSET
  617. bool "Include legacy /proc/<pid>/cpuset file"
  618. depends on KERNEL_CPUSETS
  619. config KERNEL_CGROUP_CPUACCT
  620. bool "Simple CPU accounting cgroup subsystem"
  621. default y
  622. help
  623. Provides a simple Resource Controller for monitoring the
  624. total CPU consumed by the tasks in a cgroup.
  625. config KERNEL_RESOURCE_COUNTERS
  626. bool "Resource counters"
  627. default y
  628. help
  629. This option enables controller independent resource accounting
  630. infrastructure that works with cgroups.
  631. config KERNEL_MM_OWNER
  632. bool
  633. default y if KERNEL_MEMCG
  634. config KERNEL_MEMCG
  635. bool "Memory Resource Controller for Control Groups"
  636. default y
  637. select KERNEL_FREEZER
  638. depends on KERNEL_RESOURCE_COUNTERS
  639. help
  640. Provides a memory resource controller that manages both anonymous
  641. memory and page cache. (See Documentation/cgroups/memory.txt)
  642. Note that setting this option increases fixed memory overhead
  643. associated with each page of memory in the system. By this,
  644. 20(40)bytes/PAGE_SIZE on 32(64)bit system will be occupied by memory
  645. usage tracking struct at boot. Total amount of this is printed out
  646. at boot.
  647. Only enable when you're ok with these tradeoffs and really
  648. sure you need the memory resource controller. Even when you enable
  649. this, you can set "cgroup_disable=memory" at your boot option to
  650. disable memory resource controller and you can avoid overheads
  651. (but lose benefits of memory resource controller).
  652. This config option also selects MM_OWNER config option, which
  653. could in turn add some fork/exit overhead.
  654. config KERNEL_MEMCG_SWAP
  655. bool "Memory Resource Controller Swap Extension"
  656. default y
  657. depends on KERNEL_MEMCG
  658. help
  659. Add swap management feature to memory resource controller. When you
  660. enable this, you can limit mem+swap usage per cgroup. In other words,
  661. when you disable this, memory resource controller has no cares to
  662. usage of swap...a process can exhaust all of the swap. This extension
  663. is useful when you want to avoid exhaustion swap but this itself
  664. adds more overheads and consumes memory for remembering information.
  665. Especially if you use 32bit system or small memory system, please
  666. be careful about enabling this. When memory resource controller
  667. is disabled by boot option, this will be automatically disabled and
  668. there will be no overhead from this. Even when you set this config=y,
  669. if boot option "swapaccount=0" is set, swap will not be accounted.
  670. Now, memory usage of swap_cgroup is 2 bytes per entry. If swap page
  671. size is 4096bytes, 512k per 1Gbytes of swap.
  672. config KERNEL_MEMCG_SWAP_ENABLED
  673. bool "Memory Resource Controller Swap Extension enabled by default"
  674. depends on KERNEL_MEMCG_SWAP
  675. help
  676. Memory Resource Controller Swap Extension comes with its price in
  677. a bigger memory consumption. General purpose distribution kernels
  678. which want to enable the feature but keep it disabled by default
  679. and let the user enable it by swapaccount boot command line
  680. parameter should have this option unselected.
  681. Those who want to have the feature enabled by default should
  682. select this option (if, for some reason, they need to disable it,
  683. then swapaccount=0 does the trick).
  684. config KERNEL_MEMCG_KMEM
  685. bool "Memory Resource Controller Kernel Memory accounting (EXPERIMENTAL)"
  686. default y
  687. depends on KERNEL_MEMCG
  688. help
  689. The Kernel Memory extension for Memory Resource Controller can limit
  690. the amount of memory used by kernel objects in the system. Those are
  691. fundamentally different from the entities handled by the standard
  692. Memory Controller, which are page-based, and can be swapped. Users of
  693. the kmem extension can use it to guarantee that no group of processes
  694. will ever exhaust kernel resources alone.
  695. config KERNEL_CGROUP_PERF
  696. bool "Enable perf_event per-cpu per-container group (cgroup) monitoring"
  697. select KERNEL_PERF_EVENTS
  698. help
  699. This option extends the per-cpu mode to restrict monitoring to
  700. threads which belong to the cgroup specified and run on the
  701. designated cpu.
  702. menuconfig KERNEL_CGROUP_SCHED
  703. bool "Group CPU scheduler"
  704. default y
  705. help
  706. This feature lets CPU scheduler recognize task groups and control CPU
  707. bandwidth allocation to such task groups. It uses cgroups to group
  708. tasks.
  709. if KERNEL_CGROUP_SCHED
  710. config KERNEL_FAIR_GROUP_SCHED
  711. bool "Group scheduling for SCHED_OTHER"
  712. default y
  713. config KERNEL_CFS_BANDWIDTH
  714. bool "CPU bandwidth provisioning for FAIR_GROUP_SCHED"
  715. default y
  716. depends on KERNEL_FAIR_GROUP_SCHED
  717. help
  718. This option allows users to define CPU bandwidth rates (limits) for
  719. tasks running within the fair group scheduler. Groups with no limit
  720. set are considered to be unconstrained and will run with no
  721. restriction.
  722. See tip/Documentation/scheduler/sched-bwc.txt for more information.
  723. config KERNEL_RT_GROUP_SCHED
  724. bool "Group scheduling for SCHED_RR/FIFO"
  725. default y
  726. help
  727. This feature lets you explicitly allocate real CPU bandwidth
  728. to task groups. If enabled, it will also make it impossible to
  729. schedule realtime tasks for non-root users until you allocate
  730. realtime bandwidth for them.
  731. endif
  732. config KERNEL_BLK_CGROUP
  733. bool "Block IO controller"
  734. default y
  735. help
  736. Generic block IO controller cgroup interface. This is the common
  737. cgroup interface which should be used by various IO controlling
  738. policies.
  739. Currently, CFQ IO scheduler uses it to recognize task groups and
  740. control disk bandwidth allocation (proportional time slice allocation)
  741. to such task groups. It is also used by bio throttling logic in
  742. block layer to implement upper limit in IO rates on a device.
  743. This option only enables generic Block IO controller infrastructure.
  744. One needs to also enable actual IO controlling logic/policy. For
  745. enabling proportional weight division of disk bandwidth in CFQ, set
  746. CONFIG_CFQ_GROUP_IOSCHED=y; for enabling throttling policy, set
  747. CONFIG_BLK_DEV_THROTTLING=y.
  748. if KERNEL_BLK_CGROUP
  749. config KERNEL_CFQ_GROUP_IOSCHED
  750. bool "Proportional weight of disk bandwidth in CFQ"
  751. config KERNEL_BLK_DEV_THROTTLING
  752. bool "Enable throttling policy"
  753. default y
  754. config KERNEL_BLK_DEV_THROTTLING_LOW
  755. bool "Block throttling .low limit interface support (EXPERIMENTAL)"
  756. depends on KERNEL_BLK_DEV_THROTTLING
  757. endif
  758. config KERNEL_DEBUG_BLK_CGROUP
  759. bool "Enable Block IO controller debugging"
  760. depends on KERNEL_BLK_CGROUP
  761. help
  762. Enable some debugging help. Currently it exports additional stat
  763. files in a cgroup which can be useful for debugging.
  764. config KERNEL_NET_CLS_CGROUP
  765. bool "legacy Control Group Classifier"
  766. config KERNEL_CGROUP_NET_CLASSID
  767. bool "legacy Network classid cgroup"
  768. config KERNEL_CGROUP_NET_PRIO
  769. bool "legacy Network priority cgroup"
  770. endif
  771. #
  772. # Namespace support symbols
  773. #
  774. config KERNEL_NAMESPACES
  775. bool "Enable kernel namespaces"
  776. default y if !SMALL_FLASH
  777. if KERNEL_NAMESPACES
  778. config KERNEL_UTS_NS
  779. bool "UTS namespace"
  780. default y
  781. help
  782. In this namespace, tasks see different info provided
  783. with the uname() system call.
  784. config KERNEL_IPC_NS
  785. bool "IPC namespace"
  786. default y
  787. help
  788. In this namespace, tasks work with IPC ids which correspond to
  789. different IPC objects in different namespaces.
  790. config KERNEL_USER_NS
  791. bool "User namespace (EXPERIMENTAL)"
  792. default y
  793. help
  794. This allows containers, i.e. vservers, to use user namespaces
  795. to provide different user info for different servers.
  796. config KERNEL_PID_NS
  797. bool "PID Namespaces"
  798. default y
  799. help
  800. Support process id namespaces. This allows having multiple
  801. processes with the same pid as long as they are in different
  802. pid namespaces. This is a building block of containers.
  803. config KERNEL_NET_NS
  804. bool "Network namespace"
  805. default y
  806. help
  807. Allow user space to create what appear to be multiple instances
  808. of the network stack.
  809. endif
  810. config KERNEL_DEVPTS_MULTIPLE_INSTANCES
  811. bool "Support multiple instances of devpts"
  812. default y if !SMALL_FLASH
  813. help
  814. Enable support for multiple instances of devpts filesystem.
  815. If you want to have isolated PTY namespaces (eg: in containers),
  816. say Y here. Otherwise, say N. If enabled, each mount of devpts
  817. filesystem with the '-o newinstance' option will create an
  818. independent PTY namespace.
  819. config KERNEL_POSIX_MQUEUE
  820. bool "POSIX Message Queues"
  821. default y if !SMALL_FLASH
  822. help
  823. POSIX variant of message queues is a part of IPC. In POSIX message
  824. queues every message has a priority which decides about succession
  825. of receiving it by a process. If you want to compile and run
  826. programs written e.g. for Solaris with use of its POSIX message
  827. queues (functions mq_*) say Y here.
  828. POSIX message queues are visible as a filesystem called 'mqueue'
  829. and can be mounted somewhere if you want to do filesystem
  830. operations on message queues.
  831. config KERNEL_SECCOMP_FILTER
  832. bool
  833. default y if !SMALL_FLASH
  834. config KERNEL_SECCOMP
  835. bool "Enable seccomp support"
  836. depends on !(TARGET_uml)
  837. select KERNEL_SECCOMP_FILTER
  838. default y if !SMALL_FLASH
  839. help
  840. Build kernel with support for seccomp.
  841. #
  842. # IPv4 configuration
  843. #
  844. config KERNEL_IP_MROUTE
  845. bool "Enable IPv4 multicast routing"
  846. default y
  847. help
  848. Multicast routing requires a multicast routing daemon in
  849. addition to kernel support.
  850. if KERNEL_IP_MROUTE
  851. config KERNEL_IP_MROUTE_MULTIPLE_TABLES
  852. def_bool y
  853. config KERNEL_IP_PIMSM_V1
  854. def_bool y
  855. config KERNEL_IP_PIMSM_V2
  856. def_bool y
  857. endif
  858. #
  859. # IPv6 configuration
  860. #
  861. config KERNEL_IPV6
  862. def_bool IPV6
  863. if KERNEL_IPV6
  864. config KERNEL_IPV6_MULTIPLE_TABLES
  865. def_bool y
  866. config KERNEL_IPV6_SUBTREES
  867. def_bool y
  868. config KERNEL_IPV6_MROUTE
  869. bool "Enable IPv6 multicast routing"
  870. default y
  871. help
  872. Multicast routing requires a multicast routing daemon in
  873. addition to kernel support.
  874. if KERNEL_IPV6_MROUTE
  875. config KERNEL_IPV6_MROUTE_MULTIPLE_TABLES
  876. def_bool y
  877. config KERNEL_IPV6_PIMSM_V2
  878. def_bool y
  879. endif
  880. config KERNEL_IPV6_SEG6_LWTUNNEL
  881. bool "Enable support for lightweight tunnels"
  882. default y if !SMALL_FLASH
  883. help
  884. Using lwtunnel (needed for IPv6 segment routing) requires ip-full package.
  885. config KERNEL_LWTUNNEL_BPF
  886. def_bool n
  887. endif
  888. #
  889. # Miscellaneous network configuration
  890. #
  891. config KERNEL_NET_L3_MASTER_DEV
  892. bool "L3 Master device support"
  893. help
  894. This module provides glue between core networking code and device
  895. drivers to support L3 master devices like VRF.
  896. config KERNEL_XDP_SOCKETS
  897. bool "XDP sockets support"
  898. help
  899. XDP sockets allows a channel between XDP programs and
  900. userspace applications.
  901. config KERNEL_WIRELESS_EXT
  902. def_bool n
  903. config KERNEL_WEXT_CORE
  904. def_bool KERNEL_WIRELESS_EXT
  905. config KERNEL_WEXT_PRIV
  906. def_bool KERNEL_WIRELESS_EXT
  907. config KERNEL_WEXT_PROC
  908. def_bool KERNEL_WIRELESS_EXT
  909. config KERNEL_WEXT_SPY
  910. def_bool KERNEL_WIRELESS_EXT
  911. config KERNEL_PAGE_POOL
  912. def_bool n
  913. config KERNEL_PAGE_POOL_STATS
  914. bool "Page pool stats support"
  915. depends on KERNEL_PAGE_POOL
  916. #
  917. # NFS related symbols
  918. #
  919. config KERNEL_IP_PNP
  920. bool "Compile the kernel with rootfs on NFS"
  921. help
  922. If you want to make your kernel boot off a NFS server as root
  923. filesystem, select Y here.
  924. if KERNEL_IP_PNP
  925. config KERNEL_IP_PNP_DHCP
  926. def_bool y
  927. config KERNEL_IP_PNP_BOOTP
  928. def_bool n
  929. config KERNEL_IP_PNP_RARP
  930. def_bool n
  931. config KERNEL_NFS_FS
  932. def_bool y
  933. config KERNEL_NFS_V2
  934. def_bool y
  935. config KERNEL_NFS_V3
  936. def_bool y
  937. config KERNEL_ROOT_NFS
  938. def_bool y
  939. endif
  940. menu "Filesystem ACL and attr support options"
  941. config USE_FS_ACL_ATTR
  942. bool "Use filesystem ACL and attr support by default"
  943. help
  944. Make using ACLs (e.g. POSIX ACL, NFSv4 ACL) the default
  945. for kernel and packages, except tmpfs, flash filesystems,
  946. and old NFS. Also enable userspace extended attribute support
  947. by default. (libreCMC already has an expection it will be
  948. present in the kernel).
  949. config KERNEL_FS_POSIX_ACL
  950. bool "Enable POSIX ACL support"
  951. default y if USE_FS_ACL_ATTR
  952. config KERNEL_BTRFS_FS_POSIX_ACL
  953. bool "Enable POSIX ACL for BtrFS Filesystems"
  954. select KERNEL_FS_POSIX_ACL
  955. default y if USE_FS_ACL_ATTR
  956. config KERNEL_EXT4_FS_POSIX_ACL
  957. bool "Enable POSIX ACL for Ext4 Filesystems"
  958. select KERNEL_FS_POSIX_ACL
  959. default y if USE_FS_ACL_ATTR
  960. config KERNEL_F2FS_FS_POSIX_ACL
  961. bool "Enable POSIX ACL for F2FS Filesystems"
  962. select KERNEL_FS_POSIX_ACL
  963. config KERNEL_JFFS2_FS_POSIX_ACL
  964. bool "Enable POSIX ACL for JFFS2 Filesystems"
  965. select KERNEL_FS_POSIX_ACL
  966. config KERNEL_TMPFS_POSIX_ACL
  967. bool "Enable POSIX ACL for TMPFS Filesystems"
  968. select KERNEL_FS_POSIX_ACL
  969. config KERNEL_CIFS_ACL
  970. bool "Enable CIFS ACLs"
  971. select KERNEL_FS_POSIX_ACL
  972. default y if USE_FS_ACL_ATTR
  973. config KERNEL_HFS_FS_POSIX_ACL
  974. bool "Enable POSIX ACL for HFS Filesystems"
  975. select KERNEL_FS_POSIX_ACL
  976. default y if USE_FS_ACL_ATTR
  977. config KERNEL_HFSPLUS_FS_POSIX_ACL
  978. bool "Enable POSIX ACL for HFS+ Filesystems"
  979. select KERNEL_FS_POSIX_ACL
  980. default y if USE_FS_ACL_ATTR
  981. config KERNEL_NFS_ACL_SUPPORT
  982. bool "Enable ACLs for NFS"
  983. default y if USE_FS_ACL_ATTR
  984. config KERNEL_NFS_V3_ACL_SUPPORT
  985. bool "Enable ACLs for NFSv3"
  986. config KERNEL_NFSD_V2_ACL_SUPPORT
  987. bool "Enable ACLs for NFSDv2"
  988. config KERNEL_NFSD_V3_ACL_SUPPORT
  989. bool "Enable ACLs for NFSDv3"
  990. config KERNEL_REISER_FS_POSIX_ACL
  991. bool "Enable POSIX ACLs for ReiserFS"
  992. select KERNEL_FS_POSIX_ACL
  993. default y if USE_FS_ACL_ATTR
  994. config KERNEL_XFS_POSIX_ACL
  995. bool "Enable POSIX ACLs for XFS"
  996. select KERNEL_FS_POSIX_ACL
  997. default y if USE_FS_ACL_ATTR
  998. config KERNEL_JFS_POSIX_ACL
  999. bool "Enable POSIX ACLs for JFS"
  1000. select KERNEL_FS_POSIX_ACL
  1001. default y if USE_FS_ACL_ATTR
  1002. endmenu
  1003. config KERNEL_DEVMEM
  1004. bool "/dev/mem virtual device support"
  1005. help
  1006. Say Y here if you want to support the /dev/mem device.
  1007. The /dev/mem device is used to access areas of physical
  1008. memory.
  1009. config KERNEL_DEVKMEM
  1010. bool "/dev/kmem virtual device support"
  1011. help
  1012. Say Y here if you want to support the /dev/kmem device. The
  1013. /dev/kmem device is rarely used, but can be used for certain
  1014. kind of kernel debugging operations.
  1015. config KERNEL_SQUASHFS_FRAGMENT_CACHE_SIZE
  1016. int "Number of squashfs fragments cached"
  1017. default 2 if (SMALL_FLASH && !LOW_MEMORY_FOOTPRINT)
  1018. default 3
  1019. config KERNEL_SQUASHFS_XATTR
  1020. bool "Squashfs XATTR support"
  1021. #
  1022. # compile optimization setting
  1023. #
  1024. choice
  1025. prompt "Compiler optimization level"
  1026. default KERNEL_CC_OPTIMIZE_FOR_SIZE if SMALL_FLASH
  1027. config KERNEL_CC_OPTIMIZE_FOR_PERFORMANCE
  1028. bool "Optimize for performance"
  1029. help
  1030. This is the default optimization level for the kernel, building
  1031. with the "-O2" compiler flag for best performance and most
  1032. helpful compile-time warnings.
  1033. config KERNEL_CC_OPTIMIZE_FOR_SIZE
  1034. bool "Optimize for size"
  1035. help
  1036. Enabling this option will pass "-Os" instead of "-O2" to
  1037. your compiler resulting in a smaller kernel.
  1038. endchoice
  1039. config KERNEL_AUDIT
  1040. bool "Auditing support"
  1041. config KERNEL_SECURITY
  1042. bool "Enable different security models"
  1043. config KERNEL_SECURITY_NETWORK
  1044. bool "Socket and Networking Security Hooks"
  1045. select KERNEL_SECURITY
  1046. config KERNEL_SECURITY_SELINUX
  1047. bool "NSA SELinux Support"
  1048. select KERNEL_SECURITY_NETWORK
  1049. select KERNEL_AUDIT
  1050. config KERNEL_SECURITY_SELINUX_BOOTPARAM
  1051. bool "NSA SELinux boot parameter"
  1052. depends on KERNEL_SECURITY_SELINUX
  1053. default y
  1054. config KERNEL_SECURITY_SELINUX_DISABLE
  1055. bool "NSA SELinux runtime disable"
  1056. depends on KERNEL_SECURITY_SELINUX
  1057. config KERNEL_SECURITY_SELINUX_DEVELOP
  1058. bool "NSA SELinux Development Support"
  1059. depends on KERNEL_SECURITY_SELINUX
  1060. default y
  1061. config KERNEL_SECURITY_SELINUX_SIDTAB_HASH_BITS
  1062. int
  1063. depends on KERNEL_SECURITY_SELINUX
  1064. default 9
  1065. config KERNEL_SECURITY_SELINUX_SID2STR_CACHE_SIZE
  1066. int
  1067. depends on KERNEL_SECURITY_SELINUX
  1068. default 256
  1069. config KERNEL_LSM
  1070. string
  1071. default "lockdown,yama,loadpin,safesetid,integrity,selinux"
  1072. depends on KERNEL_SECURITY_SELINUX
  1073. config KERNEL_EXT4_FS_SECURITY
  1074. bool "Ext4 Security Labels"
  1075. config KERNEL_F2FS_FS_SECURITY
  1076. bool "F2FS Security Labels"
  1077. config KERNEL_UBIFS_FS_SECURITY
  1078. bool "UBIFS Security Labels"
  1079. config KERNEL_JFFS2_FS_SECURITY
  1080. bool "JFFS2 Security Labels"
  1081. config KERNEL_WERROR
  1082. bool "Compile the kernel with warnings as errors"
  1083. help
  1084. A kernel build should not cause any compiler warnings, and this
  1085. enables the '-Werror' (for C) and '-Dwarnings' (for Rust) flags
  1086. to enforce that rule by default. Certain warnings from other tools
  1087. such as the linker may be upgraded to errors with this option as
  1088. well.
  1089. However, if you have a new (or very old) compiler or linker with odd
  1090. and unusual warnings, or you have some architecture with problems,
  1091. you may need to disable this config option in order to
  1092. successfully build the kernel.