1# SPDX-License-Identifier: GPL-2.0-only 2# 3# Library configuration 4# 5 6config BINARY_PRINTF 7 def_bool n 8 9menu "Library routines" 10 11config RAID6_PQ 12 tristate 13 14config RAID6_PQ_BENCHMARK 15 bool "Automatically choose fastest RAID6 PQ functions" 16 depends on RAID6_PQ 17 default y 18 help 19 Benchmark all available RAID6 PQ functions on init and choose the 20 fastest one. 21 22config LINEAR_RANGES 23 tristate 24 25config PACKING 26 bool "Generic bitfield packing and unpacking" 27 select BITREVERSE 28 default n 29 help 30 This option provides the packing() helper function, which permits 31 converting bitfields between a CPU-usable representation and a 32 memory representation that can have any combination of these quirks: 33 - Is little endian (bytes are reversed within a 32-bit group) 34 - The least-significant 32-bit word comes first (within a 64-bit 35 group) 36 - The most significant bit of a byte is at its right (bit 0 of a 37 register description is numerically 2^7). 38 Drivers may use these helpers to match the bit indices as described 39 in the data sheets of the peripherals they are in control of. 40 41 When in doubt, say N. 42 43config PACKING_KUNIT_TEST 44 tristate "KUnit tests for packing library" if !KUNIT_ALL_TESTS 45 depends on PACKING && KUNIT 46 default KUNIT_ALL_TESTS 47 help 48 This builds KUnit tests for the packing library. 49 50 For more information on KUnit and unit tests in general, 51 please refer to the KUnit documentation in Documentation/dev-tools/kunit/. 52 53 When in doubt, say N. 54 55config BITREVERSE 56 tristate 57 58config HAVE_ARCH_BITREVERSE 59 bool 60 default n 61 help 62 This option enables the use of hardware bit-reversal instructions on 63 architectures which support such operations. 64 65config ARCH_HAS_STRNCPY_FROM_USER 66 bool 67 68config ARCH_HAS_STRNLEN_USER 69 bool 70 71config GENERIC_STRNCPY_FROM_USER 72 def_bool !ARCH_HAS_STRNCPY_FROM_USER 73 74config GENERIC_STRNLEN_USER 75 def_bool !ARCH_HAS_STRNLEN_USER 76 77config GENERIC_NET_UTILS 78 bool 79 80source "lib/math/Kconfig" 81 82config NO_GENERIC_PCI_IOPORT_MAP 83 bool 84 85config GENERIC_IOMAP 86 bool 87 select GENERIC_PCI_IOMAP 88 89config STMP_DEVICE 90 bool 91 92config ARCH_USE_CMPXCHG_LOCKREF 93 bool 94 95config ARCH_HAS_FAST_MULTIPLIER 96 bool 97 98config ARCH_USE_SYM_ANNOTATIONS 99 bool 100 101config INDIRECT_PIO 102 bool "Access I/O in non-MMIO mode" 103 depends on ARM64 104 depends on HAS_IOPORT 105 help 106 On some platforms where no separate I/O space exists, there are I/O 107 hosts which can not be accessed in MMIO mode. Using the logical PIO 108 mechanism, the host-local I/O resource can be mapped into system 109 logic PIO space shared with MMIO hosts, such as PCI/PCIe, then the 110 system can access the I/O devices with the mapped-logic PIO through 111 I/O accessors. 112 113 This way has relatively little I/O performance cost. Please make 114 sure your devices really need this configure item enabled. 115 116 When in doubt, say N. 117 118config INDIRECT_IOMEM 119 bool 120 help 121 This is selected by other options/architectures to provide the 122 emulated iomem accessors. 123 124config INDIRECT_IOMEM_FALLBACK 125 bool 126 depends on INDIRECT_IOMEM 127 help 128 If INDIRECT_IOMEM is selected, this enables falling back to plain 129 mmio accesses when the IO memory address is not a registered 130 emulated region. 131 132config TRACE_MMIO_ACCESS 133 bool "Register read/write tracing" 134 depends on TRACING && ARCH_HAVE_TRACE_MMIO_ACCESS 135 help 136 Create tracepoints for MMIO read/write operations. These trace events 137 can be used for logging all MMIO read/write operations. 138 139source "lib/crypto/Kconfig" 140 141config CRC_CCITT 142 tristate 143 144config CRC16 145 tristate 146 147config CRC_T10DIF 148 tristate 149 150config ARCH_HAS_CRC_T10DIF 151 bool 152 153config CRC_T10DIF_ARCH 154 tristate 155 default CRC_T10DIF if ARCH_HAS_CRC_T10DIF && CRC_OPTIMIZATIONS 156 157config CRC_ITU_T 158 tristate 159 160config CRC32 161 tristate 162 select BITREVERSE 163 164config ARCH_HAS_CRC32 165 bool 166 167config CRC32_ARCH 168 tristate 169 default CRC32 if ARCH_HAS_CRC32 && CRC_OPTIMIZATIONS 170 171config CRC64 172 tristate 173 174config ARCH_HAS_CRC64 175 bool 176 177config CRC64_ARCH 178 tristate 179 default CRC64 if ARCH_HAS_CRC64 && CRC_OPTIMIZATIONS 180 181config CRC4 182 tristate 183 184config CRC7 185 tristate 186 187config LIBCRC32C 188 tristate 189 select CRC32 190 help 191 This option just selects CRC32 and is provided for compatibility 192 purposes until the users are updated to select CRC32 directly. 193 194config CRC8 195 tristate 196 197config CRC_OPTIMIZATIONS 198 bool "Enable optimized CRC implementations" if EXPERT 199 default y 200 help 201 Disabling this option reduces code size slightly by disabling the 202 architecture-optimized implementations of any CRC variants that are 203 enabled. CRC checksumming performance may get much slower. 204 205 Keep this enabled unless you're really trying to minimize the size of 206 the kernel. 207 208config XXHASH 209 tristate 210 211config AUDIT_GENERIC 212 bool 213 depends on AUDIT && !AUDIT_ARCH 214 default y 215 216config AUDIT_ARCH_COMPAT_GENERIC 217 bool 218 default n 219 220config AUDIT_COMPAT_GENERIC 221 bool 222 depends on AUDIT_GENERIC && AUDIT_ARCH_COMPAT_GENERIC && COMPAT 223 default y 224 225config RANDOM32_SELFTEST 226 bool "PRNG perform self test on init" 227 help 228 This option enables the 32 bit PRNG library functions to perform a 229 self test on initialization. 230 231# 232# compression support is select'ed if needed 233# 234config 842_COMPRESS 235 select CRC32 236 tristate 237 238config 842_DECOMPRESS 239 select CRC32 240 tristate 241 242config ZLIB_INFLATE 243 tristate 244 245config ZLIB_DEFLATE 246 tristate 247 select BITREVERSE 248 249config ZLIB_DFLTCC 250 def_bool y 251 depends on S390 252 prompt "Enable s390x DEFLATE CONVERSION CALL support for kernel zlib" 253 help 254 Enable s390x hardware support for zlib in the kernel. 255 256config LZO_COMPRESS 257 tristate 258 259config LZO_DECOMPRESS 260 tristate 261 262config LZ4_COMPRESS 263 tristate 264 265config LZ4HC_COMPRESS 266 tristate 267 268config LZ4_DECOMPRESS 269 tristate 270 271config ZSTD_COMMON 272 select XXHASH 273 tristate 274 275config ZSTD_COMPRESS 276 select ZSTD_COMMON 277 tristate 278 279config ZSTD_DECOMPRESS 280 select ZSTD_COMMON 281 tristate 282 283source "lib/xz/Kconfig" 284 285# 286# These all provide a common interface (hence the apparent duplication with 287# ZLIB_INFLATE; DECOMPRESS_GZIP is just a wrapper.) 288# 289config DECOMPRESS_GZIP 290 select ZLIB_INFLATE 291 tristate 292 293config DECOMPRESS_BZIP2 294 tristate 295 296config DECOMPRESS_LZMA 297 tristate 298 299config DECOMPRESS_XZ 300 select XZ_DEC 301 tristate 302 303config DECOMPRESS_LZO 304 select LZO_DECOMPRESS 305 tristate 306 307config DECOMPRESS_LZ4 308 select LZ4_DECOMPRESS 309 tristate 310 311config DECOMPRESS_ZSTD 312 select ZSTD_DECOMPRESS 313 tristate 314 315# 316# Generic allocator support is selected if needed 317# 318config GENERIC_ALLOCATOR 319 bool 320 321# 322# reed solomon support is select'ed if needed 323# 324config REED_SOLOMON 325 tristate 326 327config REED_SOLOMON_ENC8 328 bool 329 330config REED_SOLOMON_DEC8 331 bool 332 333config REED_SOLOMON_ENC16 334 bool 335 336config REED_SOLOMON_DEC16 337 bool 338 339# 340# BCH support is selected if needed 341# 342config BCH 343 tristate 344 select BITREVERSE 345 346config BCH_CONST_PARAMS 347 bool 348 help 349 Drivers may select this option to force specific constant 350 values for parameters 'm' (Galois field order) and 't' 351 (error correction capability). Those specific values must 352 be set by declaring default values for symbols BCH_CONST_M 353 and BCH_CONST_T. 354 Doing so will enable extra compiler optimizations, 355 improving encoding and decoding performance up to 2x for 356 usual (m,t) values (typically such that m*t < 200). 357 When this option is selected, the BCH library supports 358 only a single (m,t) configuration. This is mainly useful 359 for NAND flash board drivers requiring known, fixed BCH 360 parameters. 361 362config BCH_CONST_M 363 int 364 range 5 15 365 help 366 Constant value for Galois field order 'm'. If 'k' is the 367 number of data bits to protect, 'm' should be chosen such 368 that (k + m*t) <= 2**m - 1. 369 Drivers should declare a default value for this symbol if 370 they select option BCH_CONST_PARAMS. 371 372config BCH_CONST_T 373 int 374 help 375 Constant value for error correction capability in bits 't'. 376 Drivers should declare a default value for this symbol if 377 they select option BCH_CONST_PARAMS. 378 379# 380# Textsearch support is select'ed if needed 381# 382config TEXTSEARCH 383 bool 384 385config TEXTSEARCH_KMP 386 tristate 387 388config TEXTSEARCH_BM 389 tristate 390 391config TEXTSEARCH_FSM 392 tristate 393 394config BTREE 395 bool 396 397config INTERVAL_TREE 398 bool 399 help 400 Simple, embeddable, interval-tree. Can find the start of an 401 overlapping range in log(n) time and then iterate over all 402 overlapping nodes. The algorithm is implemented as an 403 augmented rbtree. 404 405 See: 406 407 Documentation/core-api/rbtree.rst 408 409 for more information. 410 411config INTERVAL_TREE_SPAN_ITER 412 bool 413 depends on INTERVAL_TREE 414 415config XARRAY_MULTI 416 bool 417 help 418 Support entries which occupy multiple consecutive indices in the 419 XArray. 420 421config ASSOCIATIVE_ARRAY 422 bool 423 help 424 Generic associative array. Can be searched and iterated over whilst 425 it is being modified. It is also reasonably quick to search and 426 modify. The algorithms are non-recursive, and the trees are highly 427 capacious. 428 429 See: 430 431 Documentation/core-api/assoc_array.rst 432 433 for more information. 434 435config CLOSURES 436 bool 437 438config HAS_IOMEM 439 bool 440 depends on !NO_IOMEM 441 default y 442 443config HAS_IOPORT 444 bool 445 446config HAS_IOPORT_MAP 447 bool 448 depends on HAS_IOMEM && !NO_IOPORT_MAP 449 default y 450 451source "kernel/dma/Kconfig" 452 453config SGL_ALLOC 454 bool 455 default n 456 457config IOMMU_HELPER 458 bool 459 460config CHECK_SIGNATURE 461 bool 462 463config CPUMASK_OFFSTACK 464 bool "Force CPU masks off stack" if DEBUG_PER_CPU_MAPS 465 help 466 Use dynamic allocation for cpumask_var_t, instead of putting 467 them on the stack. This is a bit more expensive, but avoids 468 stack overflow. 469 470config FORCE_NR_CPUS 471 def_bool !SMP 472 473config CPU_RMAP 474 bool 475 depends on SMP 476 477config DQL 478 bool 479 480config GLOB 481 bool 482# This actually supports modular compilation, but the module overhead 483# is ridiculous for the amount of code involved. Until an out-of-tree 484# driver asks for it, we'll just link it directly it into the kernel 485# when required. Since we're ignoring out-of-tree users, there's also 486# no need bother prompting for a manual decision: 487# prompt "glob_match() function" 488 help 489 This option provides a glob_match function for performing 490 simple text pattern matching. It originated in the ATA code 491 to blacklist particular drive models, but other device drivers 492 may need similar functionality. 493 494 All drivers in the Linux kernel tree that require this function 495 should automatically select this option. Say N unless you 496 are compiling an out-of tree driver which tells you that it 497 depends on this. 498 499config GLOB_SELFTEST 500 tristate "glob self-test on init" 501 depends on GLOB 502 help 503 This option enables a simple self-test of the glob_match 504 function on startup. It is primarily useful for people 505 working on the code to ensure they haven't introduced any 506 regressions. 507 508 It only adds a little bit of code and slows kernel boot (or 509 module load) by a small amount, so you're welcome to play with 510 it, but you probably don't need it. 511 512# 513# Netlink attribute parsing support is select'ed if needed 514# 515config NLATTR 516 bool 517 518# 519# Generic 64-bit atomic support is selected if needed 520# 521config GENERIC_ATOMIC64 522 bool 523 524config LRU_CACHE 525 tristate 526 527config CLZ_TAB 528 bool 529 530config IRQ_POLL 531 bool "IRQ polling library" 532 help 533 Helper library to poll interrupt mitigation using polling. 534 535config MPILIB 536 tristate 537 select CLZ_TAB 538 help 539 Multiprecision maths library from GnuPG. 540 It is used to implement RSA digital signature verification, 541 which is used by IMA/EVM digital signature extension. 542 543config SIGNATURE 544 tristate 545 depends on KEYS 546 select CRYPTO 547 select CRYPTO_SHA1 548 select MPILIB 549 help 550 Digital signature verification. Currently only RSA is supported. 551 Implementation is done using GnuPG MPI library 552 553config DIMLIB 554 tristate 555 depends on NET 556 help 557 Dynamic Interrupt Moderation library. 558 Implements an algorithm for dynamically changing CQ moderation values 559 according to run time performance. 560 561# 562# libfdt files, only selected if needed. 563# 564config LIBFDT 565 bool 566 567config OID_REGISTRY 568 tristate 569 help 570 Enable fast lookup object identifier registry. 571 572config UCS2_STRING 573 tristate 574 575# 576# generic vdso 577# 578source "lib/vdso/Kconfig" 579 580source "lib/fonts/Kconfig" 581 582config SG_SPLIT 583 def_bool n 584 help 585 Provides a helper to split scatterlists into chunks, each chunk being 586 a scatterlist. This should be selected by a driver or an API which 587 whishes to split a scatterlist amongst multiple DMA channels. 588 589config SG_POOL 590 def_bool n 591 help 592 Provides a helper to allocate chained scatterlists. This should be 593 selected by a driver or an API which whishes to allocate chained 594 scatterlist. 595 596# 597# sg chaining option 598# 599 600config ARCH_NO_SG_CHAIN 601 def_bool n 602 603config ARCH_HAS_PMEM_API 604 bool 605 606config MEMREGION 607 bool 608 609config ARCH_HAS_CPU_CACHE_INVALIDATE_MEMREGION 610 bool 611 612config ARCH_HAS_MEMREMAP_COMPAT_ALIGN 613 bool 614 615# use memcpy to implement user copies for nommu architectures 616config UACCESS_MEMCPY 617 bool 618 619config ARCH_HAS_UACCESS_FLUSHCACHE 620 bool 621 622# arch has a concept of a recoverable synchronous exception due to a 623# memory-read error like x86 machine-check or ARM data-abort, and 624# implements copy_mc_to_{user,kernel} to abort and report 625# 'bytes-transferred' if that exception fires when accessing the source 626# buffer. 627config ARCH_HAS_COPY_MC 628 bool 629 630# Temporary. Goes away when all archs are cleaned up 631config ARCH_STACKWALK 632 bool 633 634config STACKDEPOT 635 bool 636 select STACKTRACE 637 help 638 Stack depot: stack trace storage that avoids duplication 639 640config STACKDEPOT_ALWAYS_INIT 641 bool 642 select STACKDEPOT 643 help 644 Always initialize stack depot during early boot 645 646config STACKDEPOT_MAX_FRAMES 647 int "Maximum number of frames in trace saved in stack depot" 648 range 1 256 649 default 64 650 depends on STACKDEPOT 651 652config REF_TRACKER 653 bool 654 depends on STACKTRACE_SUPPORT 655 select STACKDEPOT 656 657config SBITMAP 658 bool 659 660config PARMAN 661 tristate "parman" if COMPILE_TEST 662 663config OBJAGG 664 tristate "objagg" if COMPILE_TEST 665 666config LWQ_TEST 667 bool "Boot-time test for lwq queuing" 668 help 669 Run boot-time test of light-weight queuing. 670 671endmenu 672 673config GENERIC_IOREMAP 674 bool 675 676config GENERIC_LIB_ASHLDI3 677 bool 678 679config GENERIC_LIB_ASHRDI3 680 bool 681 682config GENERIC_LIB_LSHRDI3 683 bool 684 685config GENERIC_LIB_MULDI3 686 bool 687 688config GENERIC_LIB_CMPDI2 689 bool 690 691config GENERIC_LIB_UCMPDI2 692 bool 693 694config GENERIC_LIB_DEVMEM_IS_ALLOWED 695 bool 696 697config PLDMFW 698 bool 699 default n 700 701config ASN1_ENCODER 702 tristate 703 704config POLYNOMIAL 705 tristate 706 707config FIRMWARE_TABLE 708 bool 709 710config UNION_FIND 711 bool 712 713config MIN_HEAP 714 bool 715