Skip to content

Commit 32643e1

Browse files
rddunlapJonathan Corbet
authored andcommitted
Documentation: admin: reorganize kernel-parameters intro
Reorganize the introduction to the kernel-parameters file to place related paragraphs together: - move module info together and near the beginning - add a Special Handling section for dashes, underscores, double quotes, cpu lists, and metric (KMG) suffixes. Expand the KMG suffixes to include TPE as well. - add a Kernel Build Options section Signed-off-by: Randy Dunlap <[email protected]> Signed-off-by: Jonathan Corbet <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 062d98b commit 32643e1

File tree

1 file changed

+23
-13
lines changed

1 file changed

+23
-13
lines changed

Documentation/admin-guide/kernel-parameters.rst

Lines changed: 23 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,16 @@ kernel command line (/proc/cmdline) and collects module parameters
2727
when it loads a module, so the kernel command line can be used for
2828
loadable modules too.
2929

30+
This document may not be entirely up to date and comprehensive. The command
31+
"modinfo -p ${modulename}" shows a current list of all parameters of a loadable
32+
module. Loadable modules, after being loaded into the running kernel, also
33+
reveal their parameters in /sys/module/${modulename}/parameters/. Some of these
34+
parameters may be changed at runtime by the command
35+
``echo -n ${value} > /sys/module/${modulename}/parameters/${parm}``.
36+
37+
Special handling
38+
----------------
39+
3040
Hyphens (dashes) and underscores are equivalent in parameter names, so::
3141

3242
log_buf_len=1M print-fatal-signals=1
@@ -39,8 +49,8 @@ Double-quotes can be used to protect spaces in values, e.g.::
3949

4050
param="spaces in here"
4151

42-
cpu lists:
43-
----------
52+
cpu lists
53+
~~~~~~~~~
4454

4555
Some kernel parameters take a list of CPUs as a value, e.g. isolcpus,
4656
nohz_full, irqaffinity, rcu_nocbs. The format of this list is:
@@ -82,12 +92,17 @@ so that "nohz_full=all" is the equivalent of "nohz_full=0-N".
8292
The semantics of "N" and "all" is supported on a level of bitmaps and holds for
8393
all users of bitmap_parselist().
8494

85-
This document may not be entirely up to date and comprehensive. The command
86-
"modinfo -p ${modulename}" shows a current list of all parameters of a loadable
87-
module. Loadable modules, after being loaded into the running kernel, also
88-
reveal their parameters in /sys/module/${modulename}/parameters/. Some of these
89-
parameters may be changed at runtime by the command
90-
``echo -n ${value} > /sys/module/${modulename}/parameters/${parm}``.
95+
Metric suffixes
96+
~~~~~~~~~~~~~~~
97+
98+
The [KMG] suffix is commonly described after a number of kernel
99+
parameter values. 'K', 'M', 'G', 'T', 'P', and 'E' suffixes are allowed.
100+
These letters represent the _binary_ multipliers 'Kilo', 'Mega', 'Giga',
101+
'Tera', 'Peta', and 'Exa', equaling 2^10, 2^20, 2^30, 2^40, 2^50, and
102+
2^60 bytes respectively. Such letter suffixes can also be entirely omitted.
103+
104+
Kernel Build Options
105+
--------------------
91106

92107
The parameters listed below are only valid if certain kernel build options
93108
were enabled and if respective hardware is present. This list should be kept
@@ -211,10 +226,5 @@ a fixed number of characters. This limit depends on the architecture
211226
and is between 256 and 4096 characters. It is defined in the file
212227
./include/uapi/asm-generic/setup.h as COMMAND_LINE_SIZE.
213228

214-
Finally, the [KMG] suffix is commonly described after a number of kernel
215-
parameter values. These 'K', 'M', and 'G' letters represent the _binary_
216-
multipliers 'Kilo', 'Mega', and 'Giga', equaling 2^10, 2^20, and 2^30
217-
bytes respectively. Such letter suffixes can also be entirely omitted:
218-
219229
.. include:: kernel-parameters.txt
220230
:literal:

0 commit comments

Comments
 (0)