19b9355a2SAndrew Clayton.. _kernelparameters: 29b9355a2SAndrew Clayton 37358bb2fSJonathan CorbetThe kernel's command-line parameters 47358bb2fSJonathan Corbet==================================== 59d85025bSMauro Carvalho Chehab 681e79063SRandy DunlapThe following is a consolidated list of the kernel parameters as implemented 781e79063SRandy Dunlapby the __setup(), early_param(), core_param() and module_param() macros 89d85025bSMauro Carvalho Chehaband sorted into English Dictionary order (defined as ignoring all 99d85025bSMauro Carvalho Chehabpunctuation and sorting digits before letters in a case insensitive 109d85025bSMauro Carvalho Chehabmanner), and with descriptions where known. 119d85025bSMauro Carvalho Chehab 1262ee81b5SStephen KittThe kernel parses parameters from the kernel command line up to "``--``"; 139d85025bSMauro Carvalho Chehabif it doesn't recognize a parameter and it doesn't contain a '.', the 149d85025bSMauro Carvalho Chehabparameter gets passed to init: parameters with '=' go into init's 159d85025bSMauro Carvalho Chehabenvironment, others are passed as command line arguments to init. 1662ee81b5SStephen KittEverything after "``--``" is passed as an argument to init. 179d85025bSMauro Carvalho Chehab 189d85025bSMauro Carvalho ChehabModule parameters can be specified in two ways: via the kernel command 199d85025bSMauro Carvalho Chehabline with a module name prefix, or via modprobe, e.g.:: 209d85025bSMauro Carvalho Chehab 219d85025bSMauro Carvalho Chehab (kernel command line) usbcore.blinkenlights=1 229d85025bSMauro Carvalho Chehab (modprobe command line) modprobe usbcore blinkenlights=1 239d85025bSMauro Carvalho Chehab 249d85025bSMauro Carvalho ChehabParameters for modules which are built into the kernel need to be 259d85025bSMauro Carvalho Chehabspecified on the kernel command line. modprobe looks through the 269d85025bSMauro Carvalho Chehabkernel command line (/proc/cmdline) and collects module parameters 279d85025bSMauro Carvalho Chehabwhen it loads a module, so the kernel command line can be used for 289d85025bSMauro Carvalho Chehabloadable modules too. 299d85025bSMauro Carvalho Chehab 30*32643e10SRandy DunlapThis document may not be entirely up to date and comprehensive. The command 31*32643e10SRandy Dunlap"modinfo -p ${modulename}" shows a current list of all parameters of a loadable 32*32643e10SRandy Dunlapmodule. Loadable modules, after being loaded into the running kernel, also 33*32643e10SRandy Dunlapreveal their parameters in /sys/module/${modulename}/parameters/. Some of these 34*32643e10SRandy Dunlapparameters may be changed at runtime by the command 35*32643e10SRandy Dunlap``echo -n ${value} > /sys/module/${modulename}/parameters/${parm}``. 36*32643e10SRandy Dunlap 37*32643e10SRandy DunlapSpecial handling 38*32643e10SRandy Dunlap---------------- 39*32643e10SRandy Dunlap 409d85025bSMauro Carvalho ChehabHyphens (dashes) and underscores are equivalent in parameter names, so:: 419d85025bSMauro Carvalho Chehab 429d85025bSMauro Carvalho Chehab log_buf_len=1M print-fatal-signals=1 439d85025bSMauro Carvalho Chehab 449d85025bSMauro Carvalho Chehabcan also be entered as:: 459d85025bSMauro Carvalho Chehab 469d85025bSMauro Carvalho Chehab log-buf-len=1M print_fatal_signals=1 479d85025bSMauro Carvalho Chehab 489d85025bSMauro Carvalho ChehabDouble-quotes can be used to protect spaces in values, e.g.:: 499d85025bSMauro Carvalho Chehab 509d85025bSMauro Carvalho Chehab param="spaces in here" 519d85025bSMauro Carvalho Chehab 52*32643e10SRandy Dunlapcpu lists 53*32643e10SRandy Dunlap~~~~~~~~~ 549d85025bSMauro Carvalho Chehab 559d85025bSMauro Carvalho ChehabSome kernel parameters take a list of CPUs as a value, e.g. isolcpus, 569d85025bSMauro Carvalho Chehabnohz_full, irqaffinity, rcu_nocbs. The format of this list is: 579d85025bSMauro Carvalho Chehab 589d85025bSMauro Carvalho Chehab <cpu number>,...,<cpu number> 599d85025bSMauro Carvalho Chehab 609d85025bSMauro Carvalho Chehabor 619d85025bSMauro Carvalho Chehab 629d85025bSMauro Carvalho Chehab <cpu number>-<cpu number> 639d85025bSMauro Carvalho Chehab (must be a positive range in ascending order) 649d85025bSMauro Carvalho Chehab 659d85025bSMauro Carvalho Chehabor a mixture 669d85025bSMauro Carvalho Chehab 679d85025bSMauro Carvalho Chehab<cpu number>,...,<cpu number>-<cpu number> 689d85025bSMauro Carvalho Chehab 699d85025bSMauro Carvalho ChehabNote that for the special case of a range one can split the range into equal 709d85025bSMauro Carvalho Chehabsized groups and for each group use some amount from the beginning of that 719d85025bSMauro Carvalho Chehabgroup: 729d85025bSMauro Carvalho Chehab 73187623b1SWolfram Sang <cpu number>-<cpu number>:<used size>/<group size> 749d85025bSMauro Carvalho Chehab 759d85025bSMauro Carvalho ChehabFor example one can add to the command line following parameter: 769d85025bSMauro Carvalho Chehab 779d85025bSMauro Carvalho Chehab isolcpus=1,2,10-20,100-2000:2/25 789d85025bSMauro Carvalho Chehab 799d85025bSMauro Carvalho Chehabwhere the final item represents CPUs 100,101,125,126,150,151,... 809d85025bSMauro Carvalho Chehab 812c4885d2SPaul GortmakerThe value "N" can be used to represent the numerically last CPU on the system, 822c4885d2SPaul Gortmakeri.e "foo_cpus=16-N" would be equivalent to "16-31" on a 32 core system. 832c4885d2SPaul Gortmaker 842c4885d2SPaul GortmakerKeep in mind that "N" is dynamic, so if system changes cause the bitmap width 852c4885d2SPaul Gortmakerto change, such as less cores in the CPU list, then N and any ranges using N 862c4885d2SPaul Gortmakerwill also change. Use the same on a small 4 core system, and "16-N" becomes 872c4885d2SPaul Gortmaker"16-3" and now the same boot input will be flagged as invalid (start > end). 889d85025bSMauro Carvalho Chehab 89b18def12SYury NorovThe special case-tolerant group name "all" has a meaning of selecting all CPUs, 90b18def12SYury Norovso that "nohz_full=all" is the equivalent of "nohz_full=0-N". 91b18def12SYury Norov 92b18def12SYury NorovThe semantics of "N" and "all" is supported on a level of bitmaps and holds for 93d0c1f8dcSAndy Shevchenkoall users of bitmap_parselist(). 949d85025bSMauro Carvalho Chehab 95*32643e10SRandy DunlapMetric suffixes 96*32643e10SRandy Dunlap~~~~~~~~~~~~~~~ 97*32643e10SRandy Dunlap 98*32643e10SRandy DunlapThe [KMG] suffix is commonly described after a number of kernel 99*32643e10SRandy Dunlapparameter values. 'K', 'M', 'G', 'T', 'P', and 'E' suffixes are allowed. 100*32643e10SRandy DunlapThese letters represent the _binary_ multipliers 'Kilo', 'Mega', 'Giga', 101*32643e10SRandy Dunlap'Tera', 'Peta', and 'Exa', equaling 2^10, 2^20, 2^30, 2^40, 2^50, and 102*32643e10SRandy Dunlap2^60 bytes respectively. Such letter suffixes can also be entirely omitted. 103*32643e10SRandy Dunlap 104*32643e10SRandy DunlapKernel Build Options 105*32643e10SRandy Dunlap-------------------- 1069d85025bSMauro Carvalho Chehab 107fe118594SRandy DunlapThe parameters listed below are only valid if certain kernel build options 108fe118594SRandy Dunlapwere enabled and if respective hardware is present. This list should be kept 109fe118594SRandy Dunlapin alphabetical order. The text in square brackets at the beginning 110fe118594SRandy Dunlapof each description states the restrictions within which a parameter 111fe118594SRandy Dunlapis applicable:: 1129d85025bSMauro Carvalho Chehab 1139d85025bSMauro Carvalho Chehab ACPI ACPI support is enabled. 1149d85025bSMauro Carvalho Chehab AGP AGP (Accelerated Graphics Port) is enabled. 1159d85025bSMauro Carvalho Chehab ALSA ALSA sound support is enabled. 1169d85025bSMauro Carvalho Chehab APIC APIC support is enabled. 1179d85025bSMauro Carvalho Chehab APM Advanced Power Management support is enabled. 118d2fc83c1SRandy Dunlap APPARMOR AppArmor support is enabled. 1199d85025bSMauro Carvalho Chehab ARM ARM architecture is enabled. 1204ad499c9SJosh Poimboeuf ARM64 ARM64 architecture is enabled. 1219d85025bSMauro Carvalho Chehab AX25 Appropriate AX.25 support is enabled. 1229d85025bSMauro Carvalho Chehab CLK Common clock infrastructure is enabled. 1239d85025bSMauro Carvalho Chehab CMA Contiguous Memory Area support is enabled. 1249d85025bSMauro Carvalho Chehab DRM Direct Rendering Management support is enabled. 1259d85025bSMauro Carvalho Chehab DYNAMIC_DEBUG Build in debug messages and enable them at runtime 12660071659SPaul E. McKenney EARLY Parameter processed too early to be embedded in initrd. 1279d85025bSMauro Carvalho Chehab EDD BIOS Enhanced Disk Drive Services (EDD) is enabled 1289d85025bSMauro Carvalho Chehab EFI EFI Partitioning (GPT) is enabled 1299d85025bSMauro Carvalho Chehab EVM Extended Verification Module 1309d85025bSMauro Carvalho Chehab FB The frame buffer device is enabled. 1319d85025bSMauro Carvalho Chehab FTRACE Function tracing enabled. 1329d85025bSMauro Carvalho Chehab GCOV GCOV profiling is enabled. 133d2fc83c1SRandy Dunlap HIBERNATION HIBERNATION is enabled. 1349d85025bSMauro Carvalho Chehab HW Appropriate hardware is enabled. 135d2fc83c1SRandy Dunlap HYPER_V HYPERV support is enabled. 1369d85025bSMauro Carvalho Chehab IMA Integrity measurement architecture is enabled. 1379d85025bSMauro Carvalho Chehab IP_PNP IP DHCP, BOOTP, or RARP is enabled. 1389d85025bSMauro Carvalho Chehab IPV6 IPv6 support is enabled. 1399d85025bSMauro Carvalho Chehab ISAPNP ISA PnP code is enabled. 1409d85025bSMauro Carvalho Chehab ISDN Appropriate ISDN support is enabled. 141d94d1053SFrederic Weisbecker ISOL CPU Isolation is enabled. 1429d85025bSMauro Carvalho Chehab JOY Appropriate joystick support is enabled. 1439d85025bSMauro Carvalho Chehab KGDB Kernel debugger support is enabled. 1449d85025bSMauro Carvalho Chehab KVM Kernel Virtual Machine support is enabled. 1459d85025bSMauro Carvalho Chehab LIBATA Libata driver is enabled 14616c52e50SHuacai Chen LOONGARCH LoongArch architecture is enabled. 1479d85025bSMauro Carvalho Chehab LOOP Loopback device support is enabled. 148fe118594SRandy Dunlap LP Printer support is enabled. 1499d85025bSMauro Carvalho Chehab M68k M68k architecture is enabled. 1509d85025bSMauro Carvalho Chehab These options have more detailed description inside of 151790a6c21SJonathan Corbet Documentation/arch/m68k/kernel-options.rst. 1529d85025bSMauro Carvalho Chehab MDA MDA console support is enabled. 1539d85025bSMauro Carvalho Chehab MIPS MIPS architecture is enabled. 1549d85025bSMauro Carvalho Chehab MOUSE Appropriate mouse support is enabled. 1559d85025bSMauro Carvalho Chehab MSI Message Signaled Interrupts (PCI). 1569d85025bSMauro Carvalho Chehab MTD MTD (Memory Technology Device) support is enabled. 1579d85025bSMauro Carvalho Chehab NET Appropriate network support is enabled. 1589d85025bSMauro Carvalho Chehab NFS Appropriate NFS support is enabled. 159fe118594SRandy Dunlap NUMA NUMA support is enabled. 160a3e1d1a7SSaravana Kannan OF Devicetree is enabled. 1619d85025bSMauro Carvalho Chehab PARISC The PA-RISC architecture is enabled. 1629d85025bSMauro Carvalho Chehab PCI PCI bus support is enabled. 1639d85025bSMauro Carvalho Chehab PCIE PCI Express support is enabled. 1649d85025bSMauro Carvalho Chehab PCMCIA The PCMCIA subsystem is enabled. 1659d85025bSMauro Carvalho Chehab PNP Plug & Play support is enabled. 1669d85025bSMauro Carvalho Chehab PPC PowerPC architecture is enabled. 1679d85025bSMauro Carvalho Chehab PPT Parallel port support is enabled. 1689d85025bSMauro Carvalho Chehab PS2 Appropriate PS/2 support is enabled. 169fe118594SRandy Dunlap PV_OPS A paravirtualized kernel is enabled. 1709d85025bSMauro Carvalho Chehab RAM RAM disk support is enabled. 1711d9807fcSTony Luck RDT Intel Resource Director Technology. 172fe118594SRandy Dunlap RISCV RISCV architecture is enabled. 1739d85025bSMauro Carvalho Chehab S390 S390 architecture is enabled. 1749d85025bSMauro Carvalho Chehab SCSI Appropriate SCSI support is enabled. 1759d85025bSMauro Carvalho Chehab A lot of drivers have their options described inside 1769d85025bSMauro Carvalho Chehab the Documentation/scsi/ sub-directory. 1779d85025bSMauro Carvalho Chehab SECURITY Different security models are enabled. 1789d85025bSMauro Carvalho Chehab SELINUX SELinux support is enabled. 1799d85025bSMauro Carvalho Chehab SERIAL Serial support is enabled. 1809d85025bSMauro Carvalho Chehab SH SuperH architecture is enabled. 1819d85025bSMauro Carvalho Chehab SMP The kernel is an SMP kernel. 1829d85025bSMauro Carvalho Chehab SPARC Sparc architecture is enabled. 1839d85025bSMauro Carvalho Chehab SUSPEND System suspend states are enabled. 184fe118594SRandy Dunlap SWSUSP Software suspend (hibernation) is enabled. 1859d85025bSMauro Carvalho Chehab TPM TPM drivers are enabled. 1869d85025bSMauro Carvalho Chehab UMS USB Mass Storage support is enabled. 1879d85025bSMauro Carvalho Chehab USB USB support is enabled. 1889d85025bSMauro Carvalho Chehab USBHID USB Human Interface Device support is enabled. 1899d85025bSMauro Carvalho Chehab V4L Video For Linux support is enabled. 1909d85025bSMauro Carvalho Chehab VGA The VGA console has been enabled. 191fe118594SRandy Dunlap VMMIO Driver for memory mapped virtio devices is enabled. 1929d85025bSMauro Carvalho Chehab VT Virtual terminal support is enabled. 1939d85025bSMauro Carvalho Chehab WDT Watchdog support is enabled. 1949d85025bSMauro Carvalho Chehab X86-32 X86-32, aka i386 architecture is enabled. 1959d85025bSMauro Carvalho Chehab X86-64 X86-64 architecture is enabled. 1969d85025bSMauro Carvalho Chehab More X86-64 boot options can be found in 197ff61f079SJonathan Corbet Documentation/arch/x86/x86_64/boot-options.rst. 1989d85025bSMauro Carvalho Chehab X86 Either 32-bit or 64-bit x86 (same as X86-32+X86-64) 1999d85025bSMauro Carvalho Chehab X86_UV SGI UV support is enabled. 2009d85025bSMauro Carvalho Chehab XEN Xen support is enabled 2014c8e3de4SBarry Song XTENSA xtensa architecture is enabled. 2029d85025bSMauro Carvalho Chehab 2039d85025bSMauro Carvalho ChehabIn addition, the following text indicates that the option:: 2049d85025bSMauro Carvalho Chehab 205fe118594SRandy Dunlap BOOT Is a boot loader parameter. 2069d85025bSMauro Carvalho Chehab BUGS= Relates to possible processor bugs on the said processor. 2079d85025bSMauro Carvalho Chehab KNL Is a kernel start-up parameter. 2089d85025bSMauro Carvalho Chehab 2099d85025bSMauro Carvalho ChehabParameters denoted with BOOT are actually interpreted by the boot 2109d85025bSMauro Carvalho Chehabloader, and have no meaning to the kernel directly. 2119d85025bSMauro Carvalho ChehabDo not modify the syntax of boot loader parameters without extreme 212ff61f079SJonathan Corbetneed or coordination with <Documentation/arch/x86/boot.rst>. 2139d85025bSMauro Carvalho Chehab 2149d85025bSMauro Carvalho ChehabThere are also arch-specific kernel-parameters not documented here. 215ff61f079SJonathan CorbetSee for example <Documentation/arch/x86/x86_64/boot-options.rst>. 2169d85025bSMauro Carvalho Chehab 2179d85025bSMauro Carvalho ChehabNote that ALL kernel parameters listed below are CASE SENSITIVE, and that 2189d85025bSMauro Carvalho Chehaba trailing = on the name of any parameter states that that parameter will 2199d85025bSMauro Carvalho Chehabbe entered as an environment variable, whereas its absence indicates that 2209d85025bSMauro Carvalho Chehabit will appear as a kernel argument readable via /proc/cmdline by programs 2219d85025bSMauro Carvalho Chehabrunning once the system is up. 2229d85025bSMauro Carvalho Chehab 2239d85025bSMauro Carvalho ChehabThe number of kernel parameters is not limited, but the length of the 2249d85025bSMauro Carvalho Chehabcomplete command line (parameters including spaces etc.) is limited to 2259d85025bSMauro Carvalho Chehaba fixed number of characters. This limit depends on the architecture 2269d85025bSMauro Carvalho Chehaband is between 256 and 4096 characters. It is defined in the file 227d2fc83c1SRandy Dunlap./include/uapi/asm-generic/setup.h as COMMAND_LINE_SIZE. 2289d85025bSMauro Carvalho Chehab 229e52347bdSJani Nikula.. include:: kernel-parameters.txt 230e52347bdSJani Nikula :literal: 231