1# SPDX-License-Identifier: GPL-2.0-only 2config CC_VERSION_TEXT 3 string 4 default "$(CC_VERSION_TEXT)" 5 help 6 This is used in unclear ways: 7 8 - Re-run Kconfig when the compiler is updated 9 The 'default' property references the environment variable, 10 CC_VERSION_TEXT so it is recorded in include/config/auto.conf.cmd. 11 When the compiler is updated, Kconfig will be invoked. 12 13 - Ensure full rebuild when the compiler is updated 14 include/linux/compiler-version.h contains this option in the comment 15 line so fixdep adds include/config/CC_VERSION_TEXT into the 16 auto-generated dependency. When the compiler is updated, syncconfig 17 will touch it and then every file will be rebuilt. 18 19config CC_IS_GCC 20 def_bool $(success,test "$(cc-name)" = GCC) 21 22config GCC_VERSION 23 int 24 default $(cc-version) if CC_IS_GCC 25 default 0 26 27config CC_IS_CLANG 28 def_bool $(success,test "$(cc-name)" = Clang) 29 30config CLANG_VERSION 31 int 32 default $(cc-version) if CC_IS_CLANG 33 default 0 34 35config AS_IS_GNU 36 def_bool $(success,test "$(as-name)" = GNU) 37 38config AS_IS_LLVM 39 def_bool $(success,test "$(as-name)" = LLVM) 40 41config AS_VERSION 42 int 43 # Use clang version if this is the integrated assembler 44 default CLANG_VERSION if AS_IS_LLVM 45 default $(as-version) 46 47config LD_IS_BFD 48 def_bool $(success,test "$(ld-name)" = BFD) 49 50config LD_VERSION 51 int 52 default $(ld-version) if LD_IS_BFD 53 default 0 54 55config LD_IS_LLD 56 def_bool $(success,test "$(ld-name)" = LLD) 57 58config LLD_VERSION 59 int 60 default $(ld-version) if LD_IS_LLD 61 default 0 62 63config RUSTC_VERSION 64 int 65 default $(rustc-version) 66 help 67 It does not depend on `RUST` since that one may need to use the version 68 in a `depends on`. 69 70config RUST_IS_AVAILABLE 71 def_bool $(success,$(srctree)/scripts/rust_is_available.sh) 72 help 73 This shows whether a suitable Rust toolchain is available (found). 74 75 Please see Documentation/rust/quick-start.rst for instructions on how 76 to satisfy the build requirements of Rust support. 77 78 In particular, the Makefile target 'rustavailable' is useful to check 79 why the Rust toolchain is not being detected. 80 81config RUSTC_LLVM_VERSION 82 int 83 default $(rustc-llvm-version) 84 85config CC_CAN_LINK 86 bool 87 default $(success,$(srctree)/scripts/cc-can-link.sh $(CC) $(CLANG_FLAGS) $(USERCFLAGS) $(USERLDFLAGS) $(m64-flag)) if 64BIT 88 default $(success,$(srctree)/scripts/cc-can-link.sh $(CC) $(CLANG_FLAGS) $(USERCFLAGS) $(USERLDFLAGS) $(m32-flag)) 89 90# Fixed in GCC 14, 13.3, 12.4 and 11.5 91# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113921 92config GCC_ASM_GOTO_OUTPUT_BROKEN 93 bool 94 depends on CC_IS_GCC 95 default y if GCC_VERSION < 110500 96 default y if GCC_VERSION >= 120000 && GCC_VERSION < 120400 97 default y if GCC_VERSION >= 130000 && GCC_VERSION < 130300 98 99config CC_HAS_ASM_GOTO_OUTPUT 100 def_bool y 101 depends on !GCC_ASM_GOTO_OUTPUT_BROKEN 102 # Detect basic support 103 depends on $(success,echo 'int foo(int x) { asm goto ("": "=r"(x) ::: bar); return x; bar: return 0; }' | $(CC) -x c - -c -o /dev/null) 104 # Detect clang (< v17) scoped label issues 105 depends on $(success,echo 'void b(void **);void* c(void);int f(void){{asm goto(""::::l0);return 0;l0:return 1;}void *x __attribute__((cleanup(b)))=c();{asm goto(""::::l1);return 2;l1:return 3;}}' | $(CC) -x c - -c -o /dev/null) 106 107config CC_HAS_ASM_GOTO_TIED_OUTPUT 108 depends on CC_HAS_ASM_GOTO_OUTPUT 109 # Detect buggy gcc and clang, fixed in gcc-11 clang-14. 110 def_bool $(success,echo 'int foo(int *x) { asm goto (".long (%l[bar]) - .": "+m"(*x) ::: bar); return *x; bar: return 0; }' | $CC -x c - -c -o /dev/null) 111 112config TOOLS_SUPPORT_RELR 113 def_bool $(success,env "CC=$(CC)" "LD=$(LD)" "NM=$(NM)" "OBJCOPY=$(OBJCOPY)" $(srctree)/scripts/tools-support-relr.sh) 114 115config CC_HAS_ASM_INLINE 116 def_bool $(success,echo 'void foo(void) { asm inline (""); }' | $(CC) -x c - -c -o /dev/null) 117 118config CC_HAS_ASSUME 119 bool 120 # clang needs to be at least 19.1.0 since the meaning of the assume 121 # attribute changed: 122 # https://github.com/llvm/llvm-project/commit/c44fa3e8a9a44c2e9a575768a3c185354b9f6c17 123 default y if CC_IS_CLANG && CLANG_VERSION >= 190100 124 # supported since gcc 13.1.0 125 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106654 126 default y if CC_IS_GCC && GCC_VERSION >= 130100 127 128config CC_HAS_NO_PROFILE_FN_ATTR 129 def_bool $(success,echo '__attribute__((no_profile_instrument_function)) int x();' | $(CC) -x c - -c -o /dev/null -Werror) 130 131config CC_HAS_COUNTED_BY 132 bool 133 # clang needs to be at least 20.1.0 to avoid potential crashes 134 # when building structures that contain __counted_by 135 # https://github.com/ClangBuiltLinux/linux/issues/2114 136 # https://github.com/llvm/llvm-project/commit/160fb1121cdf703c3ef5e61fb26c5659eb581489 137 default y if CC_IS_CLANG && CLANG_VERSION >= 200100 138 # supported since gcc 15.1.0 139 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108896 140 default y if CC_IS_GCC && GCC_VERSION >= 150100 141 142config CC_HAS_MULTIDIMENSIONAL_NONSTRING 143 def_bool $(success,echo 'char tag[][4] __attribute__((__nonstring__)) = { };' | $(CC) $(CLANG_FLAGS) -x c - -c -o /dev/null -Werror) 144 145config LD_CAN_USE_KEEP_IN_OVERLAY 146 # ld.lld prior to 21.0.0 did not support KEEP within an overlay description 147 # https://github.com/llvm/llvm-project/pull/130661 148 def_bool LD_IS_BFD || LLD_VERSION >= 210000 149 150config RUSTC_HAS_SLICE_AS_FLATTENED 151 def_bool RUSTC_VERSION >= 108000 152 153config RUSTC_HAS_COERCE_POINTEE 154 def_bool RUSTC_VERSION >= 108400 155 156config RUSTC_HAS_SPAN_FILE 157 def_bool RUSTC_VERSION >= 108800 158 159config RUSTC_HAS_UNNECESSARY_TRANSMUTES 160 def_bool RUSTC_VERSION >= 108800 161 162config RUSTC_HAS_FILE_WITH_NUL 163 def_bool RUSTC_VERSION >= 108900 164 165config RUSTC_HAS_FILE_AS_C_STR 166 def_bool RUSTC_VERSION >= 109100 167 168config PAHOLE_VERSION 169 int 170 default $(shell,$(srctree)/scripts/pahole-version.sh $(PAHOLE)) 171 172config CONSTRUCTORS 173 bool 174 175config IRQ_WORK 176 def_bool y if SMP 177 178config BUILDTIME_TABLE_SORT 179 bool 180 181config THREAD_INFO_IN_TASK 182 bool 183 help 184 Select this to move thread_info off the stack into task_struct. To 185 make this work, an arch will need to remove all thread_info fields 186 except flags and fix any runtime bugs. 187 188 One subtle change that will be needed is to use try_get_task_stack() 189 and put_task_stack() in save_thread_stack_tsk() and get_wchan(). 190 191menu "General setup" 192 193config BROKEN 194 bool 195 help 196 This option allows you to choose whether you want to try to 197 compile (and fix) old drivers that haven't been updated to 198 new infrastructure. 199 200config BROKEN_ON_SMP 201 bool 202 depends on BROKEN || !SMP 203 default y 204 205config INIT_ENV_ARG_LIMIT 206 int 207 default 32 if !UML 208 default 128 if UML 209 help 210 Maximum of each of the number of arguments and environment 211 variables passed to init from the kernel command line. 212 213config COMPILE_TEST 214 bool "Compile also drivers which will not load" 215 depends on HAS_IOMEM 216 help 217 Some drivers can be compiled on a different platform than they are 218 intended to be run on. Despite they cannot be loaded there (or even 219 when they load they cannot be used due to missing HW support), 220 developers still, opposing to distributors, might want to build such 221 drivers to compile-test them. 222 223 If you are a developer and want to build everything available, say Y 224 here. If you are a user/distributor, say N here to exclude useless 225 drivers to be distributed. 226 227config WERROR 228 bool "Compile the kernel with warnings as errors" 229 default COMPILE_TEST 230 help 231 A kernel build should not cause any compiler warnings, and this 232 enables the '-Werror' (for C) and '-Dwarnings' (for Rust) flags 233 to enforce that rule by default. Certain warnings from other tools 234 such as the linker may be upgraded to errors with this option as 235 well. 236 237 However, if you have a new (or very old) compiler or linker with odd 238 and unusual warnings, or you have some architecture with problems, 239 you may need to disable this config option in order to 240 successfully build the kernel. 241 242 If in doubt, say Y. 243 244config UAPI_HEADER_TEST 245 bool "Compile test UAPI headers" 246 depends on HEADERS_INSTALL && CC_CAN_LINK 247 help 248 Compile test headers exported to user-space to ensure they are 249 self-contained, i.e. compilable as standalone units. 250 251 If you are a developer or tester and want to ensure the exported 252 headers are self-contained, say Y here. Otherwise, choose N. 253 254config LOCALVERSION 255 string "Local version - append to kernel release" 256 help 257 Append an extra string to the end of your kernel version. 258 This will show up when you type uname, for example. 259 The string you set here will be appended after the contents of 260 any files with a filename matching localversion* in your 261 object and source tree, in that order. Your total string can 262 be a maximum of 64 characters. 263 264config LOCALVERSION_AUTO 265 bool "Automatically append version information to the version string" 266 default y 267 depends on !COMPILE_TEST 268 help 269 This will try to automatically determine if the current tree is a 270 release tree by looking for git tags that belong to the current 271 top of tree revision. 272 273 A string of the format -gxxxxxxxx will be added to the localversion 274 if a git-based tree is found. The string generated by this will be 275 appended after any matching localversion* files, and after the value 276 set in CONFIG_LOCALVERSION. 277 278 (The actual string used here is the first 12 characters produced 279 by running the command: 280 281 $ git rev-parse --verify HEAD 282 283 which is done within the script "scripts/setlocalversion".) 284 285config BUILD_SALT 286 string "Build ID Salt" 287 default "" 288 help 289 The build ID is used to link binaries and their debug info. Setting 290 this option will use the value in the calculation of the build id. 291 This is mostly useful for distributions which want to ensure the 292 build is unique between builds. It's safe to leave the default. 293 294config HAVE_KERNEL_GZIP 295 bool 296 297config HAVE_KERNEL_BZIP2 298 bool 299 300config HAVE_KERNEL_LZMA 301 bool 302 303config HAVE_KERNEL_XZ 304 bool 305 306config HAVE_KERNEL_LZO 307 bool 308 309config HAVE_KERNEL_LZ4 310 bool 311 312config HAVE_KERNEL_ZSTD 313 bool 314 315config HAVE_KERNEL_UNCOMPRESSED 316 bool 317 318choice 319 prompt "Kernel compression mode" 320 default KERNEL_GZIP 321 depends on HAVE_KERNEL_GZIP || HAVE_KERNEL_BZIP2 || HAVE_KERNEL_LZMA || HAVE_KERNEL_XZ || HAVE_KERNEL_LZO || HAVE_KERNEL_LZ4 || HAVE_KERNEL_ZSTD || HAVE_KERNEL_UNCOMPRESSED 322 help 323 The linux kernel is a kind of self-extracting executable. 324 Several compression algorithms are available, which differ 325 in efficiency, compression and decompression speed. 326 Compression speed is only relevant when building a kernel. 327 Decompression speed is relevant at each boot. 328 329 If you have any problems with bzip2 or lzma compressed 330 kernels, mail me (Alain Knaff) <alain@knaff.lu>. (An older 331 version of this functionality (bzip2 only), for 2.4, was 332 supplied by Christian Ludwig) 333 334 High compression options are mostly useful for users, who 335 are low on disk space (embedded systems), but for whom ram 336 size matters less. 337 338 If in doubt, select 'gzip' 339 340config KERNEL_GZIP 341 bool "Gzip" 342 depends on HAVE_KERNEL_GZIP 343 help 344 The old and tried gzip compression. It provides a good balance 345 between compression ratio and decompression speed. 346 347config KERNEL_BZIP2 348 bool "Bzip2" 349 depends on HAVE_KERNEL_BZIP2 350 help 351 Its compression ratio and speed is intermediate. 352 Decompression speed is slowest among the choices. The kernel 353 size is about 10% smaller with bzip2, in comparison to gzip. 354 Bzip2 uses a large amount of memory. For modern kernels you 355 will need at least 8MB RAM or more for booting. 356 357config KERNEL_LZMA 358 bool "LZMA" 359 depends on HAVE_KERNEL_LZMA 360 help 361 This compression algorithm's ratio is best. Decompression speed 362 is between gzip and bzip2. Compression is slowest. 363 The kernel size is about 33% smaller with LZMA in comparison to gzip. 364 365config KERNEL_XZ 366 bool "XZ" 367 depends on HAVE_KERNEL_XZ 368 help 369 XZ uses the LZMA2 algorithm and instruction set specific 370 BCJ filters which can improve compression ratio of executable 371 code. The size of the kernel is about 30% smaller with XZ in 372 comparison to gzip. On architectures for which there is a BCJ 373 filter (i386, x86_64, ARM, ARM64, RISC-V, big endian PowerPC, 374 and SPARC), XZ will create a few percent smaller kernel than 375 plain LZMA. 376 377 The speed is about the same as with LZMA: The decompression 378 speed of XZ is better than that of bzip2 but worse than gzip 379 and LZO. Compression is slow. 380 381config KERNEL_LZO 382 bool "LZO" 383 depends on HAVE_KERNEL_LZO 384 help 385 Its compression ratio is the poorest among the choices. The kernel 386 size is about 10% bigger than gzip; however its speed 387 (both compression and decompression) is the fastest. 388 389config KERNEL_LZ4 390 bool "LZ4" 391 depends on HAVE_KERNEL_LZ4 392 help 393 LZ4 is an LZ77-type compressor with a fixed, byte-oriented encoding. 394 A preliminary version of LZ4 de/compression tool is available at 395 <https://code.google.com/p/lz4/>. 396 397 Its compression ratio is worse than LZO. The size of the kernel 398 is about 8% bigger than LZO. But the decompression speed is 399 faster than LZO. 400 401config KERNEL_ZSTD 402 bool "ZSTD" 403 depends on HAVE_KERNEL_ZSTD 404 help 405 ZSTD is a compression algorithm targeting intermediate compression 406 with fast decompression speed. It will compress better than GZIP and 407 decompress around the same speed as LZO, but slower than LZ4. You 408 will need at least 192 KB RAM or more for booting. The zstd command 409 line tool is required for compression. 410 411config KERNEL_UNCOMPRESSED 412 bool "None" 413 depends on HAVE_KERNEL_UNCOMPRESSED 414 help 415 Produce uncompressed kernel image. This option is usually not what 416 you want. It is useful for debugging the kernel in slow simulation 417 environments, where decompressing and moving the kernel is awfully 418 slow. This option allows early boot code to skip the decompressor 419 and jump right at uncompressed kernel image. 420 421endchoice 422 423config DEFAULT_INIT 424 string "Default init path" 425 default "" 426 help 427 This option determines the default init for the system if no init= 428 option is passed on the kernel command line. If the requested path is 429 not present, we will still then move on to attempting further 430 locations (e.g. /sbin/init, etc). If this is empty, we will just use 431 the fallback list when init= is not passed. 432 433config DEFAULT_HOSTNAME 434 string "Default hostname" 435 default "(none)" 436 help 437 This option determines the default system hostname before userspace 438 calls sethostname(2). The kernel traditionally uses "(none)" here, 439 but you may wish to use a different default here to make a minimal 440 system more usable with less configuration. 441 442config SYSVIPC 443 bool "System V IPC" 444 help 445 Inter Process Communication is a suite of library functions and 446 system calls which let processes (running programs) synchronize and 447 exchange information. It is generally considered to be a good thing, 448 and some programs won't run unless you say Y here. In particular, if 449 you want to run the DOS emulator dosemu under Linux (read the 450 DOSEMU-HOWTO, available from <http://www.tldp.org/docs.html#howto>), 451 you'll need to say Y here. 452 453 You can find documentation about IPC with "info ipc" and also in 454 section 6.4 of the Linux Programmer's Guide, available from 455 <http://www.tldp.org/guides.html>. 456 457config SYSVIPC_SYSCTL 458 bool 459 depends on SYSVIPC 460 depends on SYSCTL 461 default y 462 463config SYSVIPC_COMPAT 464 def_bool y 465 depends on COMPAT && SYSVIPC 466 467config POSIX_MQUEUE 468 bool "POSIX Message Queues" 469 depends on NET 470 help 471 POSIX variant of message queues is a part of IPC. In POSIX message 472 queues every message has a priority which decides about succession 473 of receiving it by a process. If you want to compile and run 474 programs written e.g. for Solaris with use of its POSIX message 475 queues (functions mq_*) say Y here. 476 477 POSIX message queues are visible as a filesystem called 'mqueue' 478 and can be mounted somewhere if you want to do filesystem 479 operations on message queues. 480 481 If unsure, say Y. 482 483config POSIX_MQUEUE_SYSCTL 484 bool 485 depends on POSIX_MQUEUE 486 depends on SYSCTL 487 default y 488 489config WATCH_QUEUE 490 bool "General notification queue" 491 default n 492 help 493 494 This is a general notification queue for the kernel to pass events to 495 userspace by splicing them into pipes. It can be used in conjunction 496 with watches for key/keyring change notifications and device 497 notifications. 498 499 See Documentation/core-api/watch_queue.rst 500 501config CROSS_MEMORY_ATTACH 502 bool "Enable process_vm_readv/writev syscalls" 503 depends on MMU 504 default y 505 help 506 Enabling this option adds the system calls process_vm_readv and 507 process_vm_writev which allow a process with the correct privileges 508 to directly read from or write to another process' address space. 509 See the man page for more details. 510 511config AUDIT 512 bool "Auditing support" 513 depends on NET 514 help 515 Enable auditing infrastructure that can be used with another 516 kernel subsystem, such as SELinux (which requires this for 517 logging of avc messages output). System call auditing is included 518 on architectures which support it. 519 520config HAVE_ARCH_AUDITSYSCALL 521 bool 522 523config AUDITSYSCALL 524 def_bool y 525 depends on AUDIT && HAVE_ARCH_AUDITSYSCALL 526 select FSNOTIFY 527 528source "kernel/irq/Kconfig" 529source "kernel/time/Kconfig" 530source "kernel/bpf/Kconfig" 531source "kernel/Kconfig.preempt" 532 533menu "CPU/Task time and stats accounting" 534 535config VIRT_CPU_ACCOUNTING 536 bool 537 538choice 539 prompt "Cputime accounting" 540 default TICK_CPU_ACCOUNTING 541 542# Kind of a stub config for the pure tick based cputime accounting 543config TICK_CPU_ACCOUNTING 544 bool "Simple tick based cputime accounting" 545 depends on !S390 && !NO_HZ_FULL 546 help 547 This is the basic tick based cputime accounting that maintains 548 statistics about user, system and idle time spent on per jiffies 549 granularity. 550 551 If unsure, say Y. 552 553config VIRT_CPU_ACCOUNTING_NATIVE 554 bool "Deterministic task and CPU time accounting" 555 depends on HAVE_VIRT_CPU_ACCOUNTING && !NO_HZ_FULL 556 select VIRT_CPU_ACCOUNTING 557 help 558 Select this option to enable more accurate task and CPU time 559 accounting. This is done by reading a CPU counter on each 560 kernel entry and exit and on transitions within the kernel 561 between system, softirq and hardirq state, so there is a 562 small performance impact. In the case of s390 or IBM POWER > 5, 563 this also enables accounting of stolen time on logically-partitioned 564 systems. 565 566config VIRT_CPU_ACCOUNTING_GEN 567 bool "Full dynticks CPU time accounting" 568 depends on HAVE_CONTEXT_TRACKING_USER 569 depends on HAVE_VIRT_CPU_ACCOUNTING_GEN 570 depends on GENERIC_CLOCKEVENTS 571 select VIRT_CPU_ACCOUNTING 572 select CONTEXT_TRACKING_USER 573 help 574 Select this option to enable task and CPU time accounting on full 575 dynticks systems. This accounting is implemented by watching every 576 kernel-user boundaries using the context tracking subsystem. 577 The accounting is thus performed at the expense of some significant 578 overhead. 579 580 For now this is only useful if you are working on the full 581 dynticks subsystem development. 582 583 If unsure, say N. 584 585endchoice 586 587config IRQ_TIME_ACCOUNTING 588 bool "Fine granularity task level IRQ time accounting" 589 depends on HAVE_IRQ_TIME_ACCOUNTING && !VIRT_CPU_ACCOUNTING_NATIVE 590 help 591 Select this option to enable fine granularity task irq time 592 accounting. This is done by reading a timestamp on each 593 transitions between softirq and hardirq state, so there can be a 594 small performance impact. 595 596 If in doubt, say N here. 597 598config HAVE_SCHED_AVG_IRQ 599 def_bool y 600 depends on IRQ_TIME_ACCOUNTING || PARAVIRT_TIME_ACCOUNTING 601 depends on SMP 602 603config SCHED_HW_PRESSURE 604 bool 605 default y if ARM && ARM_CPU_TOPOLOGY 606 default y if ARM64 607 depends on SMP 608 depends on CPU_FREQ_THERMAL 609 help 610 Select this option to enable HW pressure accounting in the 611 scheduler. HW pressure is the value conveyed to the scheduler 612 that reflects the reduction in CPU compute capacity resulted from 613 HW throttling. HW throttling occurs when the performance of 614 a CPU is capped due to high operating temperatures as an example. 615 616 If selected, the scheduler will be able to balance tasks accordingly, 617 i.e. put less load on throttled CPUs than on non/less throttled ones. 618 619 This requires the architecture to implement 620 arch_update_hw_pressure() and arch_scale_thermal_pressure(). 621 622config BSD_PROCESS_ACCT 623 bool "BSD Process Accounting" 624 depends on MULTIUSER 625 help 626 If you say Y here, a user level program will be able to instruct the 627 kernel (via a special system call) to write process accounting 628 information to a file: whenever a process exits, information about 629 that process will be appended to the file by the kernel. The 630 information includes things such as creation time, owning user, 631 command name, memory usage, controlling terminal etc. (the complete 632 list is in the struct acct in <file:include/linux/acct.h>). It is 633 up to the user level program to do useful things with this 634 information. This is generally a good idea, so say Y. 635 636config BSD_PROCESS_ACCT_V3 637 bool "BSD Process Accounting version 3 file format" 638 depends on BSD_PROCESS_ACCT 639 default n 640 help 641 If you say Y here, the process accounting information is written 642 in a new file format that also logs the process IDs of each 643 process and its parent. Note that this file format is incompatible 644 with previous v0/v1/v2 file formats, so you will need updated tools 645 for processing it. A preliminary version of these tools is available 646 at <http://www.gnu.org/software/acct/>. 647 648config TASKSTATS 649 bool "Export task/process statistics through netlink" 650 depends on NET 651 depends on MULTIUSER 652 default n 653 help 654 Export selected statistics for tasks/processes through the 655 generic netlink interface. Unlike BSD process accounting, the 656 statistics are available during the lifetime of tasks/processes as 657 responses to commands. Like BSD accounting, they are sent to user 658 space on task exit. 659 660 Say N if unsure. 661 662config TASK_DELAY_ACCT 663 bool "Enable per-task delay accounting" 664 depends on TASKSTATS 665 select SCHED_INFO 666 help 667 Collect information on time spent by a task waiting for system 668 resources like cpu, synchronous block I/O completion and swapping 669 in pages. Such statistics can help in setting a task's priorities 670 relative to other tasks for cpu, io, rss limits etc. 671 672 Say N if unsure. 673 674config TASK_XACCT 675 bool "Enable extended accounting over taskstats" 676 depends on TASKSTATS 677 help 678 Collect extended task accounting data and send the data 679 to userland for processing over the taskstats interface. 680 681 Say N if unsure. 682 683config TASK_IO_ACCOUNTING 684 bool "Enable per-task storage I/O accounting" 685 depends on TASK_XACCT 686 help 687 Collect information on the number of bytes of storage I/O which this 688 task has caused. 689 690 Say N if unsure. 691 692config PSI 693 bool "Pressure stall information tracking" 694 select KERNFS 695 help 696 Collect metrics that indicate how overcommitted the CPU, memory, 697 and IO capacity are in the system. 698 699 If you say Y here, the kernel will create /proc/pressure/ with the 700 pressure statistics files cpu, memory, and io. These will indicate 701 the share of walltime in which some or all tasks in the system are 702 delayed due to contention of the respective resource. 703 704 In kernels with cgroup support, cgroups (cgroup2 only) will 705 have cpu.pressure, memory.pressure, and io.pressure files, 706 which aggregate pressure stalls for the grouped tasks only. 707 708 For more details see Documentation/accounting/psi.rst. 709 710 Say N if unsure. 711 712config PSI_DEFAULT_DISABLED 713 bool "Require boot parameter to enable pressure stall information tracking" 714 default n 715 depends on PSI 716 help 717 If set, pressure stall information tracking will be disabled 718 per default but can be enabled through passing psi=1 on the 719 kernel commandline during boot. 720 721 This feature adds some code to the task wakeup and sleep 722 paths of the scheduler. The overhead is too low to affect 723 common scheduling-intense workloads in practice (such as 724 webservers, memcache), but it does show up in artificial 725 scheduler stress tests, such as hackbench. 726 727 If you are paranoid and not sure what the kernel will be 728 used for, say Y. 729 730 Say N if unsure. 731 732endmenu # "CPU/Task time and stats accounting" 733 734config CPU_ISOLATION 735 bool "CPU isolation" 736 depends on SMP 737 default y 738 help 739 Make sure that CPUs running critical tasks are not disturbed by 740 any source of "noise" such as unbound workqueues, timers, kthreads... 741 Unbound jobs get offloaded to housekeeping CPUs. This is driven by 742 the "isolcpus=" boot parameter. 743 744 Say Y if unsure. 745 746source "kernel/rcu/Kconfig" 747 748config IKCONFIG 749 tristate "Kernel .config support" 750 help 751 This option enables the complete Linux kernel ".config" file 752 contents to be saved in the kernel. It provides documentation 753 of which kernel options are used in a running kernel or in an 754 on-disk kernel. This information can be extracted from the kernel 755 image file with the script scripts/extract-ikconfig and used as 756 input to rebuild the current kernel or to build another kernel. 757 It can also be extracted from a running kernel by reading 758 /proc/config.gz if enabled (below). 759 760config IKCONFIG_PROC 761 bool "Enable access to .config through /proc/config.gz" 762 depends on IKCONFIG && PROC_FS 763 help 764 This option enables access to the kernel configuration file 765 through /proc/config.gz. 766 767config IKHEADERS 768 tristate "Enable kernel headers through /sys/kernel/kheaders.tar.xz" 769 depends on SYSFS 770 help 771 This option enables access to the in-kernel headers that are generated during 772 the build process. These can be used to build eBPF tracing programs, 773 or similar programs. If you build the headers as a module, a module called 774 kheaders.ko is built which can be loaded on-demand to get access to headers. 775 776config LOG_BUF_SHIFT 777 int "Kernel log buffer size (16 => 64KB, 17 => 128KB)" 778 range 12 25 779 default 17 780 depends on PRINTK 781 help 782 Select the minimal kernel log buffer size as a power of 2. 783 The final size is affected by LOG_CPU_MAX_BUF_SHIFT config 784 parameter, see below. Any higher size also might be forced 785 by "log_buf_len" boot parameter. 786 787 Examples: 788 17 => 128 KB 789 16 => 64 KB 790 15 => 32 KB 791 14 => 16 KB 792 13 => 8 KB 793 12 => 4 KB 794 795config LOG_CPU_MAX_BUF_SHIFT 796 int "CPU kernel log buffer size contribution (13 => 8 KB, 17 => 128KB)" 797 depends on SMP 798 range 0 21 799 default 0 if BASE_SMALL 800 default 12 801 depends on PRINTK 802 help 803 This option allows to increase the default ring buffer size 804 according to the number of CPUs. The value defines the contribution 805 of each CPU as a power of 2. The used space is typically only few 806 lines however it might be much more when problems are reported, 807 e.g. backtraces. 808 809 The increased size means that a new buffer has to be allocated and 810 the original static one is unused. It makes sense only on systems 811 with more CPUs. Therefore this value is used only when the sum of 812 contributions is greater than the half of the default kernel ring 813 buffer as defined by LOG_BUF_SHIFT. The default values are set 814 so that more than 16 CPUs are needed to trigger the allocation. 815 816 Also this option is ignored when "log_buf_len" kernel parameter is 817 used as it forces an exact (power of two) size of the ring buffer. 818 819 The number of possible CPUs is used for this computation ignoring 820 hotplugging making the computation optimal for the worst case 821 scenario while allowing a simple algorithm to be used from bootup. 822 823 Examples shift values and their meaning: 824 17 => 128 KB for each CPU 825 16 => 64 KB for each CPU 826 15 => 32 KB for each CPU 827 14 => 16 KB for each CPU 828 13 => 8 KB for each CPU 829 12 => 4 KB for each CPU 830 831config PRINTK_INDEX 832 bool "Printk indexing debugfs interface" 833 depends on PRINTK && DEBUG_FS 834 help 835 Add support for indexing of all printk formats known at compile time 836 at <debugfs>/printk/index/<module>. 837 838 This can be used as part of maintaining daemons which monitor 839 /dev/kmsg, as it permits auditing the printk formats present in a 840 kernel, allowing detection of cases where monitored printks are 841 changed or no longer present. 842 843 There is no additional runtime cost to printk with this enabled. 844 845# 846# Architectures with an unreliable sched_clock() should select this: 847# 848config HAVE_UNSTABLE_SCHED_CLOCK 849 bool 850 851config GENERIC_SCHED_CLOCK 852 bool 853 854menu "Scheduler features" 855 856config UCLAMP_TASK 857 bool "Enable utilization clamping for RT/FAIR tasks" 858 depends on CPU_FREQ_GOV_SCHEDUTIL 859 help 860 This feature enables the scheduler to track the clamped utilization 861 of each CPU based on RUNNABLE tasks scheduled on that CPU. 862 863 With this option, the user can specify the min and max CPU 864 utilization allowed for RUNNABLE tasks. The max utilization defines 865 the maximum frequency a task should use while the min utilization 866 defines the minimum frequency it should use. 867 868 Both min and max utilization clamp values are hints to the scheduler, 869 aiming at improving its frequency selection policy, but they do not 870 enforce or grant any specific bandwidth for tasks. 871 872 If in doubt, say N. 873 874config UCLAMP_BUCKETS_COUNT 875 int "Number of supported utilization clamp buckets" 876 range 5 20 877 default 5 878 depends on UCLAMP_TASK 879 help 880 Defines the number of clamp buckets to use. The range of each bucket 881 will be SCHED_CAPACITY_SCALE/UCLAMP_BUCKETS_COUNT. The higher the 882 number of clamp buckets the finer their granularity and the higher 883 the precision of clamping aggregation and tracking at run-time. 884 885 For example, with the minimum configuration value we will have 5 886 clamp buckets tracking 20% utilization each. A 25% boosted tasks will 887 be refcounted in the [20..39]% bucket and will set the bucket clamp 888 effective value to 25%. 889 If a second 30% boosted task should be co-scheduled on the same CPU, 890 that task will be refcounted in the same bucket of the first task and 891 it will boost the bucket clamp effective value to 30%. 892 The clamp effective value of a bucket is reset to its nominal value 893 (20% in the example above) when there are no more tasks refcounted in 894 that bucket. 895 896 An additional boost/capping margin can be added to some tasks. In the 897 example above the 25% task will be boosted to 30% until it exits the 898 CPU. If that should be considered not acceptable on certain systems, 899 it's always possible to reduce the margin by increasing the number of 900 clamp buckets to trade off used memory for run-time tracking 901 precision. 902 903 If in doubt, use the default value. 904 905config SCHED_PROXY_EXEC 906 bool "Proxy Execution" 907 # Avoid some build failures w/ PREEMPT_RT until it can be fixed 908 depends on !PREEMPT_RT 909 # Need to investigate how to inform sched_ext of split contexts 910 depends on !SCHED_CLASS_EXT 911 # Not particularly useful until we get to multi-rq proxying 912 depends on EXPERT 913 help 914 This option enables proxy execution, a mechanism for mutex-owning 915 tasks to inherit the scheduling context of higher priority waiters. 916 917endmenu 918 919# 920# For architectures that want to enable the support for NUMA-affine scheduler 921# balancing logic: 922# 923config ARCH_SUPPORTS_NUMA_BALANCING 924 bool 925 926# 927# For architectures that prefer to flush all TLBs after a number of pages 928# are unmapped instead of sending one IPI per page to flush. The architecture 929# must provide guarantees on what happens if a clean TLB cache entry is 930# written after the unmap. Details are in mm/rmap.c near the check for 931# should_defer_flush. The architecture should also consider if the full flush 932# and the refill costs are offset by the savings of sending fewer IPIs. 933config ARCH_WANT_BATCHED_UNMAP_TLB_FLUSH 934 bool 935 936config CC_HAS_INT128 937 def_bool !$(cc-option,$(m64-flag) -D__SIZEOF_INT128__=0) && 64BIT 938 939config CC_IMPLICIT_FALLTHROUGH 940 string 941 default "-Wimplicit-fallthrough=5" if CC_IS_GCC && $(cc-option,-Wimplicit-fallthrough=5) 942 default "-Wimplicit-fallthrough" if CC_IS_CLANG && $(cc-option,-Wunreachable-code-fallthrough) 943 944# Currently, disable gcc-10+ array-bounds globally. 945# It's still broken in gcc-13, so no upper bound yet. 946config GCC10_NO_ARRAY_BOUNDS 947 def_bool y 948 949config CC_NO_ARRAY_BOUNDS 950 bool 951 default y if CC_IS_GCC && GCC_VERSION >= 90000 && GCC10_NO_ARRAY_BOUNDS 952 953# Currently, disable -Wstringop-overflow for GCC globally. 954config GCC_NO_STRINGOP_OVERFLOW 955 def_bool y 956 957config CC_NO_STRINGOP_OVERFLOW 958 bool 959 default y if CC_IS_GCC && GCC_NO_STRINGOP_OVERFLOW 960 961config CC_STRINGOP_OVERFLOW 962 bool 963 default y if CC_IS_GCC && !CC_NO_STRINGOP_OVERFLOW 964 965# 966# For architectures that know their GCC __int128 support is sound 967# 968config ARCH_SUPPORTS_INT128 969 bool 970 971# For architectures that (ab)use NUMA to represent different memory regions 972# all cpu-local but of different latencies, such as SuperH. 973# 974config ARCH_WANT_NUMA_VARIABLE_LOCALITY 975 bool 976 977config NUMA_BALANCING 978 bool "Memory placement aware NUMA scheduler" 979 depends on ARCH_SUPPORTS_NUMA_BALANCING 980 depends on !ARCH_WANT_NUMA_VARIABLE_LOCALITY 981 depends on SMP && NUMA && MIGRATION && !PREEMPT_RT 982 help 983 This option adds support for automatic NUMA aware memory/task placement. 984 The mechanism is quite primitive and is based on migrating memory when 985 it has references to the node the task is running on. 986 987 This system will be inactive on UMA systems. 988 989config NUMA_BALANCING_DEFAULT_ENABLED 990 bool "Automatically enable NUMA aware memory/task placement" 991 default y 992 depends on NUMA_BALANCING 993 help 994 If set, automatic NUMA balancing will be enabled if running on a NUMA 995 machine. 996 997config SLAB_OBJ_EXT 998 bool 999 1000menuconfig CGROUPS 1001 bool "Control Group support" 1002 select KERNFS 1003 help 1004 This option adds support for grouping sets of processes together, for 1005 use with process control subsystems such as Cpusets, CFS, memory 1006 controls or device isolation. 1007 See 1008 - Documentation/scheduler/sched-design-CFS.rst (CFS) 1009 - Documentation/admin-guide/cgroup-v1/ (features for grouping, isolation 1010 and resource control) 1011 1012 Say N if unsure. 1013 1014if CGROUPS 1015 1016config PAGE_COUNTER 1017 bool 1018 1019config CGROUP_FAVOR_DYNMODS 1020 bool "Favor dynamic modification latency reduction by default" 1021 help 1022 This option enables the "favordynmods" mount option by default 1023 which reduces the latencies of dynamic cgroup modifications such 1024 as task migrations and controller on/offs at the cost of making 1025 hot path operations such as forks and exits more expensive. 1026 1027 Say N if unsure. 1028 1029config MEMCG 1030 bool "Memory controller" 1031 select PAGE_COUNTER 1032 select EVENTFD 1033 select SLAB_OBJ_EXT 1034 select VM_EVENT_COUNTERS 1035 help 1036 Provides control over the memory footprint of tasks in a cgroup. 1037 1038config MEMCG_NMI_UNSAFE 1039 bool 1040 depends on MEMCG 1041 depends on HAVE_NMI 1042 depends on !ARCH_HAS_NMI_SAFE_THIS_CPU_OPS && !ARCH_HAVE_NMI_SAFE_CMPXCHG 1043 default y 1044 1045config MEMCG_NMI_SAFETY_REQUIRES_ATOMIC 1046 bool 1047 depends on MEMCG 1048 depends on HAVE_NMI 1049 depends on !ARCH_HAS_NMI_SAFE_THIS_CPU_OPS && ARCH_HAVE_NMI_SAFE_CMPXCHG 1050 default y 1051 1052config MEMCG_V1 1053 bool "Legacy cgroup v1 memory controller" 1054 depends on MEMCG 1055 default n 1056 help 1057 Legacy cgroup v1 memory controller which has been deprecated by 1058 cgroup v2 implementation. The v1 is there for legacy applications 1059 which haven't migrated to the new cgroup v2 interface yet. If you 1060 do not have any such application then you are completely fine leaving 1061 this option disabled. 1062 1063 Please note that feature set of the legacy memory controller is likely 1064 going to shrink due to deprecation process. New deployments with v1 1065 controller are highly discouraged. 1066 1067 Say N if unsure. 1068 1069config BLK_CGROUP 1070 bool "IO controller" 1071 depends on BLOCK 1072 default n 1073 help 1074 Generic block IO controller cgroup interface. This is the common 1075 cgroup interface which should be used by various IO controlling 1076 policies. 1077 1078 Currently, CFQ IO scheduler uses it to recognize task groups and 1079 control disk bandwidth allocation (proportional time slice allocation) 1080 to such task groups. It is also used by bio throttling logic in 1081 block layer to implement upper limit in IO rates on a device. 1082 1083 This option only enables generic Block IO controller infrastructure. 1084 One needs to also enable actual IO controlling logic/policy. For 1085 enabling proportional weight division of disk bandwidth in CFQ, set 1086 CONFIG_BFQ_GROUP_IOSCHED=y; for enabling throttling policy, set 1087 CONFIG_BLK_DEV_THROTTLING=y. 1088 1089 See Documentation/admin-guide/cgroup-v1/blkio-controller.rst for more information. 1090 1091config CGROUP_WRITEBACK 1092 bool 1093 depends on MEMCG && BLK_CGROUP 1094 default y 1095 1096menuconfig CGROUP_SCHED 1097 bool "CPU controller" 1098 default n 1099 help 1100 This feature lets CPU scheduler recognize task groups and control CPU 1101 bandwidth allocation to such task groups. It uses cgroups to group 1102 tasks. 1103 1104if CGROUP_SCHED 1105config GROUP_SCHED_WEIGHT 1106 def_bool n 1107 1108config GROUP_SCHED_BANDWIDTH 1109 def_bool n 1110 1111config FAIR_GROUP_SCHED 1112 bool "Group scheduling for SCHED_OTHER" 1113 depends on CGROUP_SCHED 1114 select GROUP_SCHED_WEIGHT 1115 default CGROUP_SCHED 1116 1117config CFS_BANDWIDTH 1118 bool "CPU bandwidth provisioning for FAIR_GROUP_SCHED" 1119 depends on FAIR_GROUP_SCHED 1120 select GROUP_SCHED_BANDWIDTH 1121 default n 1122 help 1123 This option allows users to define CPU bandwidth rates (limits) for 1124 tasks running within the fair group scheduler. Groups with no limit 1125 set are considered to be unconstrained and will run with no 1126 restriction. 1127 See Documentation/scheduler/sched-bwc.rst for more information. 1128 1129config RT_GROUP_SCHED 1130 bool "Group scheduling for SCHED_RR/FIFO" 1131 depends on CGROUP_SCHED 1132 default n 1133 help 1134 This feature lets you explicitly allocate real CPU bandwidth 1135 to task groups. If enabled, it will also make it impossible to 1136 schedule realtime tasks for non-root users until you allocate 1137 realtime bandwidth for them. 1138 See Documentation/scheduler/sched-rt-group.rst for more information. 1139 1140config RT_GROUP_SCHED_DEFAULT_DISABLED 1141 bool "Require boot parameter to enable group scheduling for SCHED_RR/FIFO" 1142 depends on RT_GROUP_SCHED 1143 default n 1144 help 1145 When set, the RT group scheduling is disabled by default. The option 1146 is in inverted form so that mere RT_GROUP_SCHED enables the group 1147 scheduling. 1148 1149 Say N if unsure. 1150 1151config EXT_GROUP_SCHED 1152 bool 1153 depends on SCHED_CLASS_EXT && CGROUP_SCHED 1154 select GROUP_SCHED_WEIGHT 1155 select GROUP_SCHED_BANDWIDTH 1156 default y 1157 1158endif #CGROUP_SCHED 1159 1160config SCHED_MM_CID 1161 def_bool y 1162 depends on SMP && RSEQ 1163 1164config UCLAMP_TASK_GROUP 1165 bool "Utilization clamping per group of tasks" 1166 depends on CGROUP_SCHED 1167 depends on UCLAMP_TASK 1168 default n 1169 help 1170 This feature enables the scheduler to track the clamped utilization 1171 of each CPU based on RUNNABLE tasks currently scheduled on that CPU. 1172 1173 When this option is enabled, the user can specify a min and max 1174 CPU bandwidth which is allowed for each single task in a group. 1175 The max bandwidth allows to clamp the maximum frequency a task 1176 can use, while the min bandwidth allows to define a minimum 1177 frequency a task will always use. 1178 1179 When task group based utilization clamping is enabled, an eventually 1180 specified task-specific clamp value is constrained by the cgroup 1181 specified clamp value. Both minimum and maximum task clamping cannot 1182 be bigger than the corresponding clamping defined at task group level. 1183 1184 If in doubt, say N. 1185 1186config CGROUP_PIDS 1187 bool "PIDs controller" 1188 help 1189 Provides enforcement of process number limits in the scope of a 1190 cgroup. Any attempt to fork more processes than is allowed in the 1191 cgroup will fail. PIDs are fundamentally a global resource because it 1192 is fairly trivial to reach PID exhaustion before you reach even a 1193 conservative kmemcg limit. As a result, it is possible to grind a 1194 system to halt without being limited by other cgroup policies. The 1195 PIDs controller is designed to stop this from happening. 1196 1197 It should be noted that organisational operations (such as attaching 1198 to a cgroup hierarchy) will *not* be blocked by the PIDs controller, 1199 since the PIDs limit only affects a process's ability to fork, not to 1200 attach to a cgroup. 1201 1202config CGROUP_RDMA 1203 bool "RDMA controller" 1204 help 1205 Provides enforcement of RDMA resources defined by IB stack. 1206 It is fairly easy for consumers to exhaust RDMA resources, which 1207 can result into resource unavailability to other consumers. 1208 RDMA controller is designed to stop this from happening. 1209 Attaching processes with active RDMA resources to the cgroup 1210 hierarchy is allowed even if can cross the hierarchy's limit. 1211 1212config CGROUP_DMEM 1213 bool "Device memory controller (DMEM)" 1214 select PAGE_COUNTER 1215 help 1216 The DMEM controller allows compatible devices to restrict device 1217 memory usage based on the cgroup hierarchy. 1218 1219 As an example, it allows you to restrict VRAM usage for applications 1220 in the DRM subsystem. 1221 1222config CGROUP_FREEZER 1223 bool "Freezer controller" 1224 help 1225 Provides a way to freeze and unfreeze all tasks in a 1226 cgroup. 1227 1228 This option affects the ORIGINAL cgroup interface. The cgroup2 memory 1229 controller includes important in-kernel memory consumers per default. 1230 1231 If you're using cgroup2, say N. 1232 1233config CGROUP_HUGETLB 1234 bool "HugeTLB controller" 1235 depends on HUGETLB_PAGE 1236 select PAGE_COUNTER 1237 default n 1238 help 1239 Provides a cgroup controller for HugeTLB pages. 1240 When you enable this, you can put a per cgroup limit on HugeTLB usage. 1241 The limit is enforced during page fault. Since HugeTLB doesn't 1242 support page reclaim, enforcing the limit at page fault time implies 1243 that, the application will get SIGBUS signal if it tries to access 1244 HugeTLB pages beyond its limit. This requires the application to know 1245 beforehand how much HugeTLB pages it would require for its use. The 1246 control group is tracked in the third page lru pointer. This means 1247 that we cannot use the controller with huge page less than 3 pages. 1248 1249config CPUSETS 1250 bool "Cpuset controller" 1251 depends on SMP 1252 select UNION_FIND 1253 help 1254 This option will let you create and manage CPUSETs which 1255 allow dynamically partitioning a system into sets of CPUs and 1256 Memory Nodes and assigning tasks to run only within those sets. 1257 This is primarily useful on large SMP or NUMA systems. 1258 1259 Say N if unsure. 1260 1261config CPUSETS_V1 1262 bool "Legacy cgroup v1 cpusets controller" 1263 depends on CPUSETS 1264 default n 1265 help 1266 Legacy cgroup v1 cpusets controller which has been deprecated by 1267 cgroup v2 implementation. The v1 is there for legacy applications 1268 which haven't migrated to the new cgroup v2 interface yet. Legacy 1269 interface includes cpuset filesystem and /proc/<pid>/cpuset. If you 1270 do not have any such application then you are completely fine leaving 1271 this option disabled. 1272 1273 Say N if unsure. 1274 1275config PROC_PID_CPUSET 1276 bool "Include legacy /proc/<pid>/cpuset file" 1277 depends on CPUSETS_V1 1278 default y 1279 1280config CGROUP_DEVICE 1281 bool "Device controller" 1282 help 1283 Provides a cgroup controller implementing whitelists for 1284 devices which a process in the cgroup can mknod or open. 1285 1286config CGROUP_CPUACCT 1287 bool "Simple CPU accounting controller" 1288 help 1289 Provides a simple controller for monitoring the 1290 total CPU consumed by the tasks in a cgroup. 1291 1292config CGROUP_PERF 1293 bool "Perf controller" 1294 depends on PERF_EVENTS 1295 help 1296 This option extends the perf per-cpu mode to restrict monitoring 1297 to threads which belong to the cgroup specified and run on the 1298 designated cpu. Or this can be used to have cgroup ID in samples 1299 so that it can monitor performance events among cgroups. 1300 1301 Say N if unsure. 1302 1303config CGROUP_BPF 1304 bool "Support for eBPF programs attached to cgroups" 1305 depends on BPF_SYSCALL 1306 select SOCK_CGROUP_DATA 1307 help 1308 Allow attaching eBPF programs to a cgroup using the bpf(2) 1309 syscall command BPF_PROG_ATTACH. 1310 1311 In which context these programs are accessed depends on the type 1312 of attachment. For instance, programs that are attached using 1313 BPF_CGROUP_INET_INGRESS will be executed on the ingress path of 1314 inet sockets. 1315 1316config CGROUP_MISC 1317 bool "Misc resource controller" 1318 default n 1319 help 1320 Provides a controller for miscellaneous resources on a host. 1321 1322 Miscellaneous scalar resources are the resources on the host system 1323 which cannot be abstracted like the other cgroups. This controller 1324 tracks and limits the miscellaneous resources used by a process 1325 attached to a cgroup hierarchy. 1326 1327 For more information, please check misc cgroup section in 1328 /Documentation/admin-guide/cgroup-v2.rst. 1329 1330config CGROUP_DEBUG 1331 bool "Debug controller" 1332 default n 1333 depends on DEBUG_KERNEL 1334 help 1335 This option enables a simple controller that exports 1336 debugging information about the cgroups framework. This 1337 controller is for control cgroup debugging only. Its 1338 interfaces are not stable. 1339 1340 Say N. 1341 1342config SOCK_CGROUP_DATA 1343 bool 1344 default n 1345 1346endif # CGROUPS 1347 1348menuconfig NAMESPACES 1349 bool "Namespaces support" if EXPERT 1350 depends on MULTIUSER 1351 default !EXPERT 1352 help 1353 Provides the way to make tasks work with different objects using 1354 the same id. For example same IPC id may refer to different objects 1355 or same user id or pid may refer to different tasks when used in 1356 different namespaces. 1357 1358if NAMESPACES 1359 1360config UTS_NS 1361 bool "UTS namespace" 1362 default y 1363 help 1364 In this namespace tasks see different info provided with the 1365 uname() system call 1366 1367config TIME_NS 1368 bool "TIME namespace" 1369 depends on GENERIC_GETTIMEOFDAY 1370 default y 1371 help 1372 In this namespace boottime and monotonic clocks can be set. 1373 The time will keep going with the same pace. 1374 1375config IPC_NS 1376 bool "IPC namespace" 1377 depends on (SYSVIPC || POSIX_MQUEUE) 1378 default y 1379 help 1380 In this namespace tasks work with IPC ids which correspond to 1381 different IPC objects in different namespaces. 1382 1383config USER_NS 1384 bool "User namespace" 1385 default n 1386 help 1387 This allows containers, i.e. vservers, to use user namespaces 1388 to provide different user info for different servers. 1389 1390 When user namespaces are enabled in the kernel it is 1391 recommended that the MEMCG option also be enabled and that 1392 user-space use the memory control groups to limit the amount 1393 of memory a memory unprivileged users can use. 1394 1395 If unsure, say N. 1396 1397config PID_NS 1398 bool "PID Namespaces" 1399 default y 1400 help 1401 Support process id namespaces. This allows having multiple 1402 processes with the same pid as long as they are in different 1403 pid namespaces. This is a building block of containers. 1404 1405config NET_NS 1406 bool "Network namespace" 1407 depends on NET 1408 default y 1409 help 1410 Allow user space to create what appear to be multiple instances 1411 of the network stack. 1412 1413endif # NAMESPACES 1414 1415config CHECKPOINT_RESTORE 1416 bool "Checkpoint/restore support" 1417 depends on PROC_FS 1418 select PROC_CHILDREN 1419 select KCMP 1420 default n 1421 help 1422 Enables additional kernel features in a sake of checkpoint/restore. 1423 In particular it adds auxiliary prctl codes to setup process text, 1424 data and heap segment sizes, and a few additional /proc filesystem 1425 entries. 1426 1427 If unsure, say N here. 1428 1429config SCHED_AUTOGROUP 1430 bool "Automatic process group scheduling" 1431 select CGROUPS 1432 select CGROUP_SCHED 1433 select FAIR_GROUP_SCHED 1434 help 1435 This option optimizes the scheduler for common desktop workloads by 1436 automatically creating and populating task groups. This separation 1437 of workloads isolates aggressive CPU burners (like build jobs) from 1438 desktop applications. Task group autogeneration is currently based 1439 upon task session. 1440 1441config RELAY 1442 bool "Kernel->user space relay support (formerly relayfs)" 1443 select IRQ_WORK 1444 help 1445 This option enables support for relay interface support in 1446 certain file systems (such as debugfs). 1447 It is designed to provide an efficient mechanism for tools and 1448 facilities to relay large amounts of data from kernel space to 1449 user space. 1450 1451 If unsure, say N. 1452 1453config BLK_DEV_INITRD 1454 bool "Initial RAM filesystem and RAM disk (initramfs/initrd) support" 1455 help 1456 The initial RAM filesystem is a ramfs which is loaded by the 1457 boot loader (loadlin or lilo) and that is mounted as root 1458 before the normal boot procedure. It is typically used to 1459 load modules needed to mount the "real" root file system, 1460 etc. See <file:Documentation/admin-guide/initrd.rst> for details. 1461 1462 If RAM disk support (BLK_DEV_RAM) is also included, this 1463 also enables initial RAM disk (initrd) support and adds 1464 15 Kbytes (more on some other architectures) to the kernel size. 1465 1466 If unsure say Y. 1467 1468if BLK_DEV_INITRD 1469 1470source "usr/Kconfig" 1471 1472endif 1473 1474config BOOT_CONFIG 1475 bool "Boot config support" 1476 select BLK_DEV_INITRD if !BOOT_CONFIG_EMBED 1477 help 1478 Extra boot config allows system admin to pass a config file as 1479 complemental extension of kernel cmdline when booting. 1480 The boot config file must be attached at the end of initramfs 1481 with checksum, size and magic word. 1482 See <file:Documentation/admin-guide/bootconfig.rst> for details. 1483 1484 If unsure, say Y. 1485 1486config BOOT_CONFIG_FORCE 1487 bool "Force unconditional bootconfig processing" 1488 depends on BOOT_CONFIG 1489 default y if BOOT_CONFIG_EMBED 1490 help 1491 With this Kconfig option set, BOOT_CONFIG processing is carried 1492 out even when the "bootconfig" kernel-boot parameter is omitted. 1493 In fact, with this Kconfig option set, there is no way to 1494 make the kernel ignore the BOOT_CONFIG-supplied kernel-boot 1495 parameters. 1496 1497 If unsure, say N. 1498 1499config BOOT_CONFIG_EMBED 1500 bool "Embed bootconfig file in the kernel" 1501 depends on BOOT_CONFIG 1502 help 1503 Embed a bootconfig file given by BOOT_CONFIG_EMBED_FILE in the 1504 kernel. Usually, the bootconfig file is loaded with the initrd 1505 image. But if the system doesn't support initrd, this option will 1506 help you by embedding a bootconfig file while building the kernel. 1507 1508 If unsure, say N. 1509 1510config BOOT_CONFIG_EMBED_FILE 1511 string "Embedded bootconfig file path" 1512 depends on BOOT_CONFIG_EMBED 1513 help 1514 Specify a bootconfig file which will be embedded to the kernel. 1515 This bootconfig will be used if there is no initrd or no other 1516 bootconfig in the initrd. 1517 1518config INITRAMFS_PRESERVE_MTIME 1519 bool "Preserve cpio archive mtimes in initramfs" 1520 depends on BLK_DEV_INITRD 1521 default y 1522 help 1523 Each entry in an initramfs cpio archive carries an mtime value. When 1524 enabled, extracted cpio items take this mtime, with directory mtime 1525 setting deferred until after creation of any child entries. 1526 1527 If unsure, say Y. 1528 1529config INITRAMFS_TEST 1530 bool "Test initramfs cpio archive extraction" if !KUNIT_ALL_TESTS 1531 depends on BLK_DEV_INITRD && KUNIT=y 1532 default KUNIT_ALL_TESTS 1533 help 1534 Build KUnit tests for initramfs. See Documentation/dev-tools/kunit 1535 1536choice 1537 prompt "Compiler optimization level" 1538 default CC_OPTIMIZE_FOR_PERFORMANCE 1539 1540config CC_OPTIMIZE_FOR_PERFORMANCE 1541 bool "Optimize for performance (-O2)" 1542 help 1543 This is the default optimization level for the kernel, building 1544 with the "-O2" compiler flag for best performance and most 1545 helpful compile-time warnings. 1546 1547config CC_OPTIMIZE_FOR_SIZE 1548 bool "Optimize for size (-Os)" 1549 help 1550 Choosing this option will pass "-Os" to your compiler resulting 1551 in a smaller kernel. 1552 1553endchoice 1554 1555config HAVE_LD_DEAD_CODE_DATA_ELIMINATION 1556 bool 1557 help 1558 This requires that the arch annotates or otherwise protects 1559 its external entry points from being discarded. Linker scripts 1560 must also merge .text.*, .data.*, and .bss.* correctly into 1561 output sections. Care must be taken not to pull in unrelated 1562 sections (e.g., '.text.init'). Typically '.' in section names 1563 is used to distinguish them from label names / C identifiers. 1564 1565config LD_DEAD_CODE_DATA_ELIMINATION 1566 bool "Dead code and data elimination (EXPERIMENTAL)" 1567 depends on HAVE_LD_DEAD_CODE_DATA_ELIMINATION 1568 depends on EXPERT 1569 depends on $(cc-option,-ffunction-sections -fdata-sections) 1570 depends on $(ld-option,--gc-sections) 1571 help 1572 Enable this if you want to do dead code and data elimination with 1573 the linker by compiling with -ffunction-sections -fdata-sections, 1574 and linking with --gc-sections. 1575 1576 This can reduce on disk and in-memory size of the kernel 1577 code and static data, particularly for small configs and 1578 on small systems. This has the possibility of introducing 1579 silently broken kernel if the required annotations are not 1580 present. This option is not well tested yet, so use at your 1581 own risk. 1582 1583config LD_ORPHAN_WARN 1584 def_bool y 1585 depends on ARCH_WANT_LD_ORPHAN_WARN 1586 depends on $(ld-option,--orphan-handling=warn) 1587 depends on $(ld-option,--orphan-handling=error) 1588 1589config LD_ORPHAN_WARN_LEVEL 1590 string 1591 depends on LD_ORPHAN_WARN 1592 default "error" if WERROR 1593 default "warn" 1594 1595config SYSCTL 1596 bool 1597 1598config HAVE_UID16 1599 bool 1600 1601config SYSCTL_EXCEPTION_TRACE 1602 bool 1603 help 1604 Enable support for /proc/sys/debug/exception-trace. 1605 1606config SYSCTL_ARCH_UNALIGN_NO_WARN 1607 bool 1608 help 1609 Enable support for /proc/sys/kernel/ignore-unaligned-usertrap 1610 Allows arch to define/use @no_unaligned_warning to possibly warn 1611 about unaligned access emulation going on under the hood. 1612 1613config SYSCTL_ARCH_UNALIGN_ALLOW 1614 bool 1615 help 1616 Enable support for /proc/sys/kernel/unaligned-trap 1617 Allows arches to define/use @unaligned_enabled to runtime toggle 1618 the unaligned access emulation. 1619 see arch/parisc/kernel/unaligned.c for reference 1620 1621config SYSFS_SYSCALL 1622 bool "Sysfs syscall support" 1623 default n 1624 help 1625 sys_sysfs is an obsolete system call no longer supported in libc. 1626 Note that disabling this option is more secure but might break 1627 compatibility with some systems. 1628 1629 If unsure say N here. 1630 1631config HAVE_PCSPKR_PLATFORM 1632 bool 1633 1634menuconfig EXPERT 1635 bool "Configure standard kernel features (expert users)" 1636 # Unhide debug options, to make the on-by-default options visible 1637 select DEBUG_KERNEL 1638 help 1639 This option allows certain base kernel options and settings 1640 to be disabled or tweaked. This is for specialized 1641 environments which can tolerate a "non-standard" kernel. 1642 Only use this if you really know what you are doing. 1643 1644config UID16 1645 bool "Enable 16-bit UID system calls" if EXPERT 1646 depends on HAVE_UID16 && MULTIUSER 1647 default y 1648 help 1649 This enables the legacy 16-bit UID syscall wrappers. 1650 1651config MULTIUSER 1652 bool "Multiple users, groups and capabilities support" if EXPERT 1653 default y 1654 help 1655 This option enables support for non-root users, groups and 1656 capabilities. 1657 1658 If you say N here, all processes will run with UID 0, GID 0, and all 1659 possible capabilities. Saying N here also compiles out support for 1660 system calls related to UIDs, GIDs, and capabilities, such as setuid, 1661 setgid, and capset. 1662 1663 If unsure, say Y here. 1664 1665config SGETMASK_SYSCALL 1666 bool "sgetmask/ssetmask syscalls support" if EXPERT 1667 default PARISC || M68K || PPC || MIPS || X86 || SPARC || MICROBLAZE || SUPERH 1668 help 1669 sys_sgetmask and sys_ssetmask are obsolete system calls 1670 no longer supported in libc but still enabled by default in some 1671 architectures. 1672 1673 If unsure, leave the default option here. 1674 1675config FHANDLE 1676 bool "open by fhandle syscalls" if EXPERT 1677 select EXPORTFS 1678 default y 1679 help 1680 If you say Y here, a user level program will be able to map 1681 file names to handle and then later use the handle for 1682 different file system operations. This is useful in implementing 1683 userspace file servers, which now track files using handles instead 1684 of names. The handle would remain the same even if file names 1685 get renamed. Enables open_by_handle_at(2) and name_to_handle_at(2) 1686 syscalls. 1687 1688config POSIX_TIMERS 1689 bool "Posix Clocks & timers" if EXPERT 1690 default y 1691 help 1692 This includes native support for POSIX timers to the kernel. 1693 Some embedded systems have no use for them and therefore they 1694 can be configured out to reduce the size of the kernel image. 1695 1696 When this option is disabled, the following syscalls won't be 1697 available: timer_create, timer_gettime: timer_getoverrun, 1698 timer_settime, timer_delete, clock_adjtime, getitimer, 1699 setitimer, alarm. Furthermore, the clock_settime, clock_gettime, 1700 clock_getres and clock_nanosleep syscalls will be limited to 1701 CLOCK_REALTIME, CLOCK_MONOTONIC and CLOCK_BOOTTIME only. 1702 1703 If unsure say y. 1704 1705config PRINTK 1706 default y 1707 bool "Enable support for printk" if EXPERT 1708 select IRQ_WORK 1709 help 1710 This option enables normal printk support. Removing it 1711 eliminates most of the message strings from the kernel image 1712 and makes the kernel more or less silent. As this makes it 1713 very difficult to diagnose system problems, saying N here is 1714 strongly discouraged. 1715 1716config PRINTK_RINGBUFFER_KUNIT_TEST 1717 tristate "KUnit Test for the printk ringbuffer" if !KUNIT_ALL_TESTS 1718 depends on PRINTK && KUNIT 1719 default KUNIT_ALL_TESTS 1720 help 1721 This builds the printk ringbuffer KUnit test suite. 1722 1723 For more information on KUnit and unit tests in general, please refer 1724 to the KUnit documentation. 1725 1726 If unsure, say N. 1727 1728config BUG 1729 bool "BUG() support" if EXPERT 1730 default y 1731 help 1732 Disabling this option eliminates support for BUG and WARN, reducing 1733 the size of your kernel image and potentially quietly ignoring 1734 numerous fatal conditions. You should only consider disabling this 1735 option for embedded systems with no facilities for reporting errors. 1736 Just say Y. 1737 1738config ELF_CORE 1739 depends on COREDUMP 1740 default y 1741 bool "Enable ELF core dumps" if EXPERT 1742 help 1743 Enable support for generating core dumps. Disabling saves about 4k. 1744 1745 1746config PCSPKR_PLATFORM 1747 bool "Enable PC-Speaker support" if EXPERT 1748 depends on HAVE_PCSPKR_PLATFORM 1749 select I8253_LOCK 1750 default y 1751 help 1752 This option allows to disable the internal PC-Speaker 1753 support, saving some memory. 1754 1755config BASE_SMALL 1756 bool "Enable smaller-sized data structures for core" if EXPERT 1757 help 1758 Enabling this option reduces the size of miscellaneous core 1759 kernel data structures. This saves memory on small machines, 1760 but may reduce performance. 1761 1762config FUTEX 1763 bool "Enable futex support" if EXPERT 1764 depends on !(SPARC32 && SMP) 1765 default y 1766 imply RT_MUTEXES 1767 help 1768 Disabling this option will cause the kernel to be built without 1769 support for "fast userspace mutexes". The resulting kernel may not 1770 run glibc-based applications correctly. 1771 1772config FUTEX_PI 1773 bool 1774 depends on FUTEX && RT_MUTEXES 1775 default y 1776 1777config FUTEX_PRIVATE_HASH 1778 bool 1779 depends on FUTEX && !BASE_SMALL && MMU 1780 default y 1781 1782config FUTEX_MPOL 1783 bool 1784 depends on FUTEX && NUMA 1785 default y 1786 1787config EPOLL 1788 bool "Enable eventpoll support" if EXPERT 1789 default y 1790 help 1791 Disabling this option will cause the kernel to be built without 1792 support for epoll family of system calls. 1793 1794config SIGNALFD 1795 bool "Enable signalfd() system call" if EXPERT 1796 default y 1797 help 1798 Enable the signalfd() system call that allows to receive signals 1799 on a file descriptor. 1800 1801 If unsure, say Y. 1802 1803config TIMERFD 1804 bool "Enable timerfd() system call" if EXPERT 1805 default y 1806 help 1807 Enable the timerfd() system call that allows to receive timer 1808 events on a file descriptor. 1809 1810 If unsure, say Y. 1811 1812config EVENTFD 1813 bool "Enable eventfd() system call" if EXPERT 1814 default y 1815 help 1816 Enable the eventfd() system call that allows to receive both 1817 kernel notification (ie. KAIO) or userspace notifications. 1818 1819 If unsure, say Y. 1820 1821config SHMEM 1822 bool "Use full shmem filesystem" if EXPERT 1823 default y 1824 depends on MMU 1825 help 1826 The shmem is an internal filesystem used to manage shared memory. 1827 It is backed by swap and manages resource limits. It is also exported 1828 to userspace as tmpfs if TMPFS is enabled. Disabling this 1829 option replaces shmem and tmpfs with the much simpler ramfs code, 1830 which may be appropriate on small systems without swap. 1831 1832config AIO 1833 bool "Enable AIO support" if EXPERT 1834 default y 1835 help 1836 This option enables POSIX asynchronous I/O which may by used 1837 by some high performance threaded applications. Disabling 1838 this option saves about 7k. 1839 1840config IO_URING 1841 bool "Enable IO uring support" if EXPERT 1842 select IO_WQ 1843 default y 1844 help 1845 This option enables support for the io_uring interface, enabling 1846 applications to submit and complete IO through submission and 1847 completion rings that are shared between the kernel and application. 1848 1849config GCOV_PROFILE_URING 1850 bool "Enable GCOV profiling on the io_uring subsystem" 1851 depends on IO_URING && GCOV_KERNEL 1852 help 1853 Enable GCOV profiling on the io_uring subsystem, to facilitate 1854 code coverage testing. 1855 1856 If unsure, say N. 1857 1858 Note that this will have a negative impact on the performance of 1859 the io_uring subsystem, hence this should only be enabled for 1860 specific test purposes. 1861 1862config IO_URING_MOCK_FILE 1863 tristate "Enable io_uring mock files (Experimental)" if EXPERT 1864 default n 1865 depends on IO_URING 1866 help 1867 Enable mock files for io_uring subststem testing. The ABI might 1868 still change, so it's still experimental and should only be enabled 1869 for specific test purposes. 1870 1871 If unsure, say N. 1872 1873config ADVISE_SYSCALLS 1874 bool "Enable madvise/fadvise syscalls" if EXPERT 1875 default y 1876 help 1877 This option enables the madvise and fadvise syscalls, used by 1878 applications to advise the kernel about their future memory or file 1879 usage, improving performance. If building an embedded system where no 1880 applications use these syscalls, you can disable this option to save 1881 space. 1882 1883config MEMBARRIER 1884 bool "Enable membarrier() system call" if EXPERT 1885 default y 1886 help 1887 Enable the membarrier() system call that allows issuing memory 1888 barriers across all running threads, which can be used to distribute 1889 the cost of user-space memory barriers asymmetrically by transforming 1890 pairs of memory barriers into pairs consisting of membarrier() and a 1891 compiler barrier. 1892 1893 If unsure, say Y. 1894 1895config KCMP 1896 bool "Enable kcmp() system call" if EXPERT 1897 help 1898 Enable the kernel resource comparison system call. It provides 1899 user-space with the ability to compare two processes to see if they 1900 share a common resource, such as a file descriptor or even virtual 1901 memory space. 1902 1903 If unsure, say N. 1904 1905config RSEQ 1906 bool "Enable rseq() system call" if EXPERT 1907 default y 1908 depends on HAVE_RSEQ 1909 select MEMBARRIER 1910 help 1911 Enable the restartable sequences system call. It provides a 1912 user-space cache for the current CPU number value, which 1913 speeds up getting the current CPU number from user-space, 1914 as well as an ABI to speed up user-space operations on 1915 per-CPU data. 1916 1917 If unsure, say Y. 1918 1919config DEBUG_RSEQ 1920 default n 1921 bool "Enable debugging of rseq() system call" if EXPERT 1922 depends on RSEQ && DEBUG_KERNEL 1923 help 1924 Enable extra debugging checks for the rseq system call. 1925 1926 If unsure, say N. 1927 1928config CACHESTAT_SYSCALL 1929 bool "Enable cachestat() system call" if EXPERT 1930 default y 1931 help 1932 Enable the cachestat system call, which queries the page cache 1933 statistics of a file (number of cached pages, dirty pages, 1934 pages marked for writeback, (recently) evicted pages). 1935 1936 If unsure say Y here. 1937 1938config KALLSYMS 1939 bool "Load all symbols for debugging/ksymoops" if EXPERT 1940 default y 1941 help 1942 Say Y here to let the kernel print out symbolic crash information and 1943 symbolic stack backtraces. This increases the size of the kernel 1944 somewhat, as all symbols have to be loaded into the kernel image. 1945 1946config KALLSYMS_SELFTEST 1947 bool "Test the basic functions and performance of kallsyms" 1948 depends on KALLSYMS 1949 default n 1950 help 1951 Test the basic functions and performance of some interfaces, such as 1952 kallsyms_lookup_name. It also calculates the compression rate of the 1953 kallsyms compression algorithm for the current symbol set. 1954 1955 Start self-test automatically after system startup. Suggest executing 1956 "dmesg | grep kallsyms_selftest" to collect test results. "finish" is 1957 displayed in the last line, indicating that the test is complete. 1958 1959config KALLSYMS_ALL 1960 bool "Include all symbols in kallsyms" 1961 depends on DEBUG_KERNEL && KALLSYMS 1962 help 1963 Normally kallsyms only contains the symbols of functions for nicer 1964 OOPS messages and backtraces (i.e., symbols from the text and inittext 1965 sections). This is sufficient for most cases. And only if you want to 1966 enable kernel live patching, or other less common use cases (e.g., 1967 when a debugger is used) all symbols are required (i.e., names of 1968 variables from the data sections, etc). 1969 1970 This option makes sure that all symbols are loaded into the kernel 1971 image (i.e., symbols from all sections) in cost of increased kernel 1972 size (depending on the kernel configuration, it may be 300KiB or 1973 something like this). 1974 1975 Say N unless you really need all symbols, or kernel live patching. 1976 1977# end of the "standard kernel features (expert users)" menu 1978 1979config ARCH_HAS_MEMBARRIER_CALLBACKS 1980 bool 1981 1982config ARCH_HAS_MEMBARRIER_SYNC_CORE 1983 bool 1984 1985config ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS 1986 bool 1987 help 1988 Control MSEAL_SYSTEM_MAPPINGS access based on architecture. 1989 1990 A 64-bit kernel is required for the memory sealing feature. 1991 No specific hardware features from the CPU are needed. 1992 1993 To enable this feature, the architecture needs to update their 1994 special mappings calls to include the sealing flag and confirm 1995 that it doesn't unmap/remap system mappings during the life 1996 time of the process. The existence of this flag for an architecture 1997 implies that it does not require the remapping of the system 1998 mappings during process lifetime, so sealing these mappings is safe 1999 from a kernel perspective. 2000 2001 After the architecture enables this, a distribution can set 2002 CONFIG_MSEAL_SYSTEM_MAPPING to manage access to the feature. 2003 2004 For complete descriptions of memory sealing, please see 2005 Documentation/userspace-api/mseal.rst 2006 2007config HAVE_PERF_EVENTS 2008 bool 2009 help 2010 See tools/perf/design.txt for details. 2011 2012config GUEST_PERF_EVENTS 2013 bool 2014 depends on HAVE_PERF_EVENTS 2015 2016config PERF_USE_VMALLOC 2017 bool 2018 help 2019 See tools/perf/design.txt for details 2020 2021menu "Kernel Performance Events And Counters" 2022 2023config PERF_EVENTS 2024 bool "Kernel performance events and counters" 2025 default y if PROFILING 2026 depends on HAVE_PERF_EVENTS 2027 select IRQ_WORK 2028 help 2029 Enable kernel support for various performance events provided 2030 by software and hardware. 2031 2032 Software events are supported either built-in or via the 2033 use of generic tracepoints. 2034 2035 Most modern CPUs support performance events via performance 2036 counter registers. These registers count the number of certain 2037 types of hw events: such as instructions executed, cachemisses 2038 suffered, or branches mis-predicted - without slowing down the 2039 kernel or applications. These registers can also trigger interrupts 2040 when a threshold number of events have passed - and can thus be 2041 used to profile the code that runs on that CPU. 2042 2043 The Linux Performance Event subsystem provides an abstraction of 2044 these software and hardware event capabilities, available via a 2045 system call and used by the "perf" utility in tools/perf/. It 2046 provides per task and per CPU counters, and it provides event 2047 capabilities on top of those. 2048 2049 Say Y if unsure. 2050 2051config DEBUG_PERF_USE_VMALLOC 2052 default n 2053 bool "Debug: use vmalloc to back perf mmap() buffers" 2054 depends on PERF_EVENTS && DEBUG_KERNEL && !PPC 2055 select PERF_USE_VMALLOC 2056 help 2057 Use vmalloc memory to back perf mmap() buffers. 2058 2059 Mostly useful for debugging the vmalloc code on platforms 2060 that don't require it. 2061 2062 Say N if unsure. 2063 2064endmenu 2065 2066config SYSTEM_DATA_VERIFICATION 2067 def_bool n 2068 select SYSTEM_TRUSTED_KEYRING 2069 select KEYS 2070 select CRYPTO 2071 select CRYPTO_RSA 2072 select ASYMMETRIC_KEY_TYPE 2073 select ASYMMETRIC_PUBLIC_KEY_SUBTYPE 2074 select ASN1 2075 select OID_REGISTRY 2076 select X509_CERTIFICATE_PARSER 2077 select PKCS7_MESSAGE_PARSER 2078 help 2079 Provide PKCS#7 message verification using the contents of the system 2080 trusted keyring to provide public keys. This then can be used for 2081 module verification, kexec image verification and firmware blob 2082 verification. 2083 2084config PROFILING 2085 bool "Profiling support" 2086 help 2087 Say Y here to enable the extended profiling support mechanisms used 2088 by profilers. 2089 2090config RUST 2091 bool "Rust support" 2092 depends on HAVE_RUST 2093 depends on RUST_IS_AVAILABLE 2094 select EXTENDED_MODVERSIONS if MODVERSIONS 2095 depends on !MODVERSIONS || GENDWARFKSYMS 2096 depends on !GCC_PLUGIN_RANDSTRUCT 2097 depends on !RANDSTRUCT 2098 depends on !DEBUG_INFO_BTF || (PAHOLE_HAS_LANG_EXCLUDE && !LTO) 2099 depends on !CFI || HAVE_CFI_ICALL_NORMALIZE_INTEGERS_RUSTC 2100 select CFI_ICALL_NORMALIZE_INTEGERS if CFI 2101 depends on !CALL_PADDING || RUSTC_VERSION >= 108100 2102 depends on !KASAN_SW_TAGS 2103 depends on !(MITIGATION_RETHUNK && KASAN) || RUSTC_VERSION >= 108300 2104 help 2105 Enables Rust support in the kernel. 2106 2107 This allows other Rust-related options, like drivers written in Rust, 2108 to be selected. 2109 2110 It is also required to be able to load external kernel modules 2111 written in Rust. 2112 2113 See Documentation/rust/ for more information. 2114 2115 If unsure, say N. 2116 2117config RUSTC_VERSION_TEXT 2118 string 2119 depends on RUST 2120 default "$(RUSTC_VERSION_TEXT)" 2121 help 2122 See `CC_VERSION_TEXT`. 2123 2124config BINDGEN_VERSION_TEXT 2125 string 2126 depends on RUST 2127 # The dummy parameter `workaround-for-0.69.0` is required to support 0.69.0 2128 # (https://github.com/rust-lang/rust-bindgen/pull/2678) and 0.71.0 2129 # (https://github.com/rust-lang/rust-bindgen/pull/3040). It can be removed 2130 # when the minimum version is upgraded past the latter (0.69.1 and 0.71.1 2131 # both fixed the issue). 2132 default "$(shell,$(BINDGEN) --version workaround-for-0.69.0 2>/dev/null)" 2133 2134# 2135# Place an empty function call at each tracepoint site. Can be 2136# dynamically changed for a probe function. 2137# 2138config TRACEPOINTS 2139 bool 2140 select TASKS_TRACE_RCU 2141 2142source "kernel/Kconfig.kexec" 2143 2144endmenu # General setup 2145 2146source "arch/Kconfig" 2147 2148config RT_MUTEXES 2149 bool 2150 default y if PREEMPT_RT 2151 2152config MODULE_SIG_FORMAT 2153 def_bool n 2154 select SYSTEM_DATA_VERIFICATION 2155 2156source "kernel/module/Kconfig" 2157 2158config INIT_ALL_POSSIBLE 2159 bool 2160 help 2161 Back when each arch used to define their own cpu_online_mask and 2162 cpu_possible_mask, some of them chose to initialize cpu_possible_mask 2163 with all 1s, and others with all 0s. When they were centralised, 2164 it was better to provide this option than to break all the archs 2165 and have several arch maintainers pursuing me down dark alleys. 2166 2167source "block/Kconfig" 2168 2169config PREEMPT_NOTIFIERS 2170 bool 2171 2172config PADATA 2173 depends on SMP 2174 bool 2175 2176config ASN1 2177 tristate 2178 help 2179 Build a simple ASN.1 grammar compiler that produces a bytecode output 2180 that can be interpreted by the ASN.1 stream decoder and used to 2181 inform it as to what tags are to be expected in a stream and what 2182 functions to call on what tags. 2183 2184source "kernel/Kconfig.locks" 2185 2186config ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE 2187 bool 2188 2189config ARCH_HAS_PREPARE_SYNC_CORE_CMD 2190 bool 2191 2192config ARCH_HAS_SYNC_CORE_BEFORE_USERMODE 2193 bool 2194 2195# It may be useful for an architecture to override the definitions of the 2196# SYSCALL_DEFINE() and __SYSCALL_DEFINEx() macros in <linux/syscalls.h> 2197# and the COMPAT_ variants in <linux/compat.h>, in particular to use a 2198# different calling convention for syscalls. They can also override the 2199# macros for not-implemented syscalls in kernel/sys_ni.c and 2200# kernel/time/posix-stubs.c. All these overrides need to be available in 2201# <asm/syscall_wrapper.h>. 2202config ARCH_HAS_SYSCALL_WRAPPER 2203 def_bool n 2204