chiark / gitweb /
stop complaining about unknown kernel cmdline options
authorLennart Poettering <lennart@poettering.net>
Thu, 19 Jun 2014 14:55:20 +0000 (16:55 +0200)
committerLennart Poettering <lennart@poettering.net>
Thu, 19 Jun 2014 14:55:20 +0000 (16:55 +0200)
Also stop warning about unknown kernel cmdline options in the various
tools, not just in PID 1

src/cryptsetup/cryptsetup-generator.c
src/fsck/fsck.c
src/fstab-generator/fstab-generator.c
src/gpt-auto-generator/gpt-auto-generator.c
src/quotacheck/quotacheck.c

index dfdca1e47b4e3ce82ddf7fd6027a5f89e748b5d8..9530e44bd3491fcbd693e244ab8be4b801fa1f61 100644 (file)
@@ -291,8 +291,7 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
                 if (!arg_keyfile)
                         return log_oom();
 
-        } else if (startswith(key, "luks.") || startswith(key, "rd.luks."))
-                log_warning("Unknown kernel switch %s. Ignoring.", key);
+        }
 
         return 0;
 }
index cb2f5734ea069ddf11a0a9ddd17bfd44ce23ddb6..0b572e59f5ab387a11cfb8e6746a093fae7abd8c 100644 (file)
@@ -86,7 +86,8 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
                 else if (streq(value, "skip"))
                         arg_skip = true;
                 else
-                        log_warning("Invalid fsck.mode= parameter. Ignoring.");
+                        log_warning("Invalid fsck.mode= parameter '%s'. Ignoring.", value);
+
         } else if (streq(key, "fsck.repair") && value) {
 
                 if (streq(value, "preen"))
@@ -96,13 +97,14 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
                 else if (streq(value, "no"))
                         arg_repair = "-n";
                 else
-                        log_warning("Invalid fsck.repair= parameter. Ignoring.");
-        } else if (startswith(key, "fsck."))
-                log_warning("Invalid fsck parameter. Ignoring.");
+                        log_warning("Invalid fsck.repair= parameter '%s'. Ignoring.", value);
+        }
+
 #ifdef HAVE_SYSV_COMPAT
         else if (streq(key, "fastboot") && !value) {
                 log_warning("Please pass 'fsck.mode=skip' rather than 'fastboot' on the kernel command line.");
                 arg_skip = true;
+
         } else if (streq(key, "forcefsck") && !value) {
                 log_warning("Please pass 'fsck.mode=force' rather than 'forcefsck' on the kernel command line.");
                 arg_force = true;
@@ -113,6 +115,7 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
 }
 
 static void test_files(void) {
+
 #ifdef HAVE_SYSV_COMPAT
         if (access("/fastboot", F_OK) >= 0) {
                 log_error("Please pass 'fsck.mode=skip' on the kernel command line rather than creating /fastboot on the root file system.");
index a9a5c0203f2cb8276a1486b1d2b809cad0d87efb..63c36b5f945cc29cff16dc160be0481b811d0b94 100644 (file)
@@ -486,8 +486,6 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
                 arg_root_rw = true;
         else if (streq(key, "ro") && !value)
                 arg_root_rw = false;
-        else if (startswith(key, "fstab.") || startswith(key, "rd.fstab."))
-                log_warning("Unknown kernel switch %s. Ignoring.", key);
 
         return 0;
 }
index 78643c9a3ce09eb05eb1c072c03c5bd6bb85913e..7dcbbfe497a52b66f0bf23de38222813b63de115 100644 (file)
@@ -695,8 +695,6 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
                 arg_root_rw = true;
         else if (streq(key, "ro") && !value)
                 arg_root_rw = false;
-        else if (startswith(key, "systemd.gpt-auto.") || startswith(key, "rd.systemd.gpt-auto."))
-                log_warning("Unknown kernel switch %s. Ignoring.", key);
 
         return 0;
 }
index efd6e18308ae5d201d8d850d06679e668285b2d7..ed95b48c63e6881cb1cccee32edc882a655b48e4 100644 (file)
@@ -42,10 +42,9 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
                 else if (streq(value, "skip"))
                         arg_skip = true;
                 else
-                        log_warning("Invalid quotacheck.mode= parameter. Ignoring.");
+                        log_warning("Invalid quotacheck.mode= parameter '%s'. Ignoring.", value);
+        }
 
-        } else if (startswith(key, "quotacheck."))
-                log_warning("Invalid quotacheck parameter. Ignoring.");
 #ifdef HAVE_SYSV_COMPAT
         else if (streq(key, "forcequotacheck") && !value) {
                 log_warning("Please use 'quotacheck.mode=force' rather than 'forcequotacheck' on the kernel command line.");
@@ -57,6 +56,7 @@ static int parse_proc_cmdline_item(const char *key, const char *value) {
 }
 
 static void test_files(void) {
+
 #ifdef HAVE_SYSV_COMPAT
         if (access("/forcequotacheck", F_OK) >= 0) {
                 log_error("Please pass 'quotacheck.mode=force' on the kernel command line rather than creating /forcequotacheck on the root file system.");