summaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-12-12 18:29:15 +0100
committerLennart Poettering <lennart@poettering.net>2016-12-21 19:09:08 +0100
commit1d84ad944520fc3e062ef518c4db4e1d3a1866af (patch)
treef1761716cb0471e4ceb54df72c2d1eb9e4430487 /man
parent2467cc55f139cf540dc1ed6da5f3774fcbab4475 (diff)
util-lib: various improvements to kernel command line parsing
This improves kernel command line parsing in a number of ways: a) An kernel option "foo_bar=xyz" is now considered equivalent to "foo-bar-xyz", i.e. when comparing kernel command line option names "-" and "_" are now considered equivalent (this only applies to the option names though, not the option values!). Most of our kernel options used "-" as word separator in kernel command line options so far, but some used "_". With this change, which was a source of confusion for users (well, at least of one user: myself, I just couldn't remember that it's systemd.debug-shell, not systemd.debug_shell). Considering both as equivalent is inspired how modern kernel module loading normalizes all kernel module names to use underscores now too. b) All options previously using a dash for separating words in kernel command line options now use an underscore instead, in all documentation and in code. Since a) has been implemented this should not create any compatibility problems, but normalizes our documentation and our code. c) All kernel command line options which take booleans (or are boolean-like) have been reworked so that "foobar" (without argument) is now equivalent to "foobar=1" (but not "foobar=0"), thus normalizing the handling of our boolean arguments. Specifically this means systemd.debug-shell and systemd_debug_shell=1 are now entirely equivalent. d) All kernel command line options which take an argument, and where no argument is specified will now result in a log message. e.g. passing just "systemd.unit" will no result in a complain that it needs an argument. This is implemented in the proc_cmdline_missing_value() function. e) There's now a call proc_cmdline_get_bool() similar to proc_cmdline_get_key() that parses booleans (following the logic explained in c). f) The proc_cmdline_parse() call's boolean argument has been replaced by a new flags argument that takes a common set of bits with proc_cmdline_get_key(). g) All kernel command line APIs now begin with the same "proc_cmdline_" prefix. h) There are now tests for much of this. Yay!
Diffstat (limited to 'man')
-rw-r--r--man/kernel-command-line.xml22
-rw-r--r--man/systemd-debug-generator.xml2
-rw-r--r--man/systemd-modules-load.service.xml4
-rw-r--r--man/systemd-udevd.service.xml16
4 files changed, 22 insertions, 22 deletions
diff --git a/man/kernel-command-line.xml b/man/kernel-command-line.xml
index c86e45265f..78e45e66a9 100644
--- a/man/kernel-command-line.xml
+++ b/man/kernel-command-line.xml
@@ -102,7 +102,7 @@
<varlistentry>
<term><varname>systemd.mask=</varname></term>
<term><varname>systemd.wants=</varname></term>
- <term><varname>systemd.debug-shell</varname></term>
+ <term><varname>systemd.debug_shell</varname></term>
<listitem>
<para>Additional parameters understood by
<citerefentry><refentrytitle>systemd-debug-generator</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
@@ -236,14 +236,14 @@
</varlistentry>
<varlistentry>
- <term><varname>udev.log-priority=</varname></term>
- <term><varname>rd.udev.log-priority=</varname></term>
- <term><varname>udev.children-max=</varname></term>
- <term><varname>rd.udev.children-max=</varname></term>
- <term><varname>udev.exec-delay=</varname></term>
- <term><varname>rd.udev.exec-delay=</varname></term>
- <term><varname>udev.event-timeout=</varname></term>
- <term><varname>rd.udev.event-timeout=</varname></term>
+ <term><varname>udev.log_priority=</varname></term>
+ <term><varname>rd.udev.log_priority=</varname></term>
+ <term><varname>udev.children_max=</varname></term>
+ <term><varname>rd.udev.children_max=</varname></term>
+ <term><varname>udev.exec_delay=</varname></term>
+ <term><varname>rd.udev.exec_delay=</varname></term>
+ <term><varname>udev.event_timeout=</varname></term>
+ <term><varname>rd.udev.event_timeout=</varname></term>
<term><varname>net.ifnames=</varname></term>
<listitem>
@@ -332,8 +332,8 @@
</varlistentry>
<varlistentry>
- <term><varname>modules-load=</varname></term>
- <term><varname>rd.modules-load=</varname></term>
+ <term><varname>modules_load=</varname></term>
+ <term><varname>rd.modules_load=</varname></term>
<listitem>
<para>Load a specific kernel module early at boot. For
diff --git a/man/systemd-debug-generator.xml b/man/systemd-debug-generator.xml
index 5c5e9fc4a1..0a66b9bbf9 100644
--- a/man/systemd-debug-generator.xml
+++ b/man/systemd-debug-generator.xml
@@ -70,7 +70,7 @@
the initial transaction. This is useful to start one or more
additional units at boot. May be specified more than once.</para>
- <para>If the <option>systemd.debug-shell</option> option is
+ <para>If the <option>systemd.debug_shell</option> option is
specified, the debug shell service
<literal>debug-shell.service</literal> is pulled into the boot
transaction. It will spawn a debug shell on tty9 during early
diff --git a/man/systemd-modules-load.service.xml b/man/systemd-modules-load.service.xml
index b25929b2e4..ee097d7f5c 100644
--- a/man/systemd-modules-load.service.xml
+++ b/man/systemd-modules-load.service.xml
@@ -73,8 +73,8 @@
<variablelist class='kernel-commandline-options'>
<varlistentry>
- <term><varname>modules-load=</varname></term>
- <term><varname>rd.modules-load=</varname></term>
+ <term><varname>modules_load=</varname></term>
+ <term><varname>rd.modules_load=</varname></term>
<listitem><para>Takes a comma-separated list of kernel modules
to statically load during early boot. The option prefixed with
diff --git a/man/systemd-udevd.service.xml b/man/systemd-udevd.service.xml
index 243fd06471..81b957b0c8 100644
--- a/man/systemd-udevd.service.xml
+++ b/man/systemd-udevd.service.xml
@@ -133,22 +133,22 @@
<para>Parameters starting with "rd." will be read when
<command>systemd-udevd</command> is used in an initrd.</para>
<varlistentry>
- <term><varname>udev.log-priority=</varname></term>
- <term><varname>rd.udev.log-priority=</varname></term>
+ <term><varname>udev.log_priority=</varname></term>
+ <term><varname>rd.udev.log_priority=</varname></term>
<listitem>
<para>Set the log level.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><varname>udev.children-max=</varname></term>
- <term><varname>rd.udev.children-max=</varname></term>
+ <term><varname>udev.children_max=</varname></term>
+ <term><varname>rd.udev.children_max=</varname></term>
<listitem>
<para>Limit the number of events executed in parallel.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><varname>udev.exec-delay=</varname></term>
- <term><varname>rd.udev.exec-delay=</varname></term>
+ <term><varname>udev.exec_delay=</varname></term>
+ <term><varname>rd.udev.exec_delay=</varname></term>
<listitem>
<para>Delay the execution of <varname>RUN</varname> instructions by the given
number of seconds. This option might be useful when
@@ -157,8 +157,8 @@
</listitem>
</varlistentry>
<varlistentry>
- <term><varname>udev.event-timeout=</varname></term>
- <term><varname>rd.udev.event-timeout=</varname></term>
+ <term><varname>udev.event_timeout=</varname></term>
+ <term><varname>rd.udev.event_timeout=</varname></term>
<listitem>
<para>Wait for events to finish up to the given number
of seconds. This option might be useful if events are