]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
sd-boot: sprinkle some ", ignoring" trailing messages
authorEmil Velikov <emil.velikov@collabora.com>
Fri, 6 Oct 2023 15:16:23 +0000 (16:16 +0100)
committerEmil Velikov <emil.l.velikov@gmail.com>
Fri, 6 Oct 2023 15:21:04 +0000 (16:21 +0100)
As mentioned by Lennart:

  ... we typically suffix such messages with ", ignoring", to indicate
  that we don't consider this fatal for anything.

Update config_defaults_load_from_file() to follow that pattern.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
src/boot/efi/boot.c

index c5806d83d974d85e4a592e6340865e97a4da92b8..0f61c302a382cf4682ee262eaab8bc44af36ed75 100644 (file)
@@ -1217,7 +1217,8 @@ static void config_defaults_load_from_file(Config *config, char *content) {
                         else {
                                 uint64_t u;
                                 if (!parse_number8(value, &u, NULL) || u > TIMEOUT_TYPE_MAX) {
-                                        log_error("Error parsing 'timeout' config option: %s", value);
+                                        log_error("Error parsing 'timeout' config option, ignoring: %s",
+                                                  value);
                                         continue;
                                 }
                                 config->timeout_sec_config = u;
@@ -1228,7 +1229,7 @@ static void config_defaults_load_from_file(Config *config, char *content) {
 
                 if (streq8(key, "default")) {
                         if (value[0] == '@' && !strcaseeq8(value, "@saved")) {
-                                log_error("Unsupported special entry identifier: %s", value);
+                                log_error("Unsupported special entry identifier, ignoring: %s", value);
                                 continue;
                         }
                         free(config->entry_default_config);
@@ -1239,35 +1240,36 @@ static void config_defaults_load_from_file(Config *config, char *content) {
                 if (streq8(key, "editor")) {
                         err = parse_boolean(value, &config->editor);
                         if (err != EFI_SUCCESS)
-                                log_error("Error parsing 'editor' config option: %s", value);
+                                log_error("Error parsing 'editor' config option, ignoring: %s", value);
                         continue;
                 }
 
                 if (streq8(key, "auto-entries")) {
                         err = parse_boolean(value, &config->auto_entries);
                         if (err != EFI_SUCCESS)
-                                log_error("Error parsing 'auto-entries' config option: %s", value);
+                                log_error("Error parsing 'auto-entries' config option, ignoring: %s", value);
                         continue;
                 }
 
                 if (streq8(key, "auto-firmware")) {
                         err = parse_boolean(value, &config->auto_firmware);
                         if (err != EFI_SUCCESS)
-                                log_error("Error parsing 'auto-firmware' config option: %s", value);
+                                log_error("Error parsing 'auto-firmware' config option, ignoring: %s", value);
                         continue;
                 }
 
                 if (streq8(key, "beep")) {
                         err = parse_boolean(value, &config->beep);
                         if (err != EFI_SUCCESS)
-                                log_error("Error parsing 'beep' config option: %s", value);
+                                log_error("Error parsing 'beep' config option, ignoring: %s", value);
                         continue;
                 }
 
                 if (streq8(key, "reboot-for-bitlocker")) {
                         err = parse_boolean(value, &config->reboot_for_bitlocker);
                         if (err != EFI_SUCCESS)
-                                log_error("Error parsing 'reboot-for-bitlocker' config option: %s", value);
+                                log_error("Error parsing 'reboot-for-bitlocker' config option, ignoring: %s",
+                                          value);
                 }
 
                 if (streq8(key, "secure-boot-enroll")) {
@@ -1280,7 +1282,8 @@ static void config_defaults_load_from_file(Config *config, char *content) {
                         else if (streq8(value, "off"))
                                 config->secure_boot_enroll = ENROLL_OFF;
                         else
-                                log_error("Error parsing 'secure-boot-enroll' config option: %s", value);
+                                log_error("Error parsing 'secure-boot-enroll' config option, ignoring: %s",
+                                          value);
                         continue;
                 }
 
@@ -1294,7 +1297,8 @@ static void config_defaults_load_from_file(Config *config, char *content) {
                         else {
                                 uint64_t u;
                                 if (!parse_number8(value, &u, NULL) || u > CONSOLE_MODE_RANGE_MAX) {
-                                        log_error("Error parsing 'console-mode' config option: %s", value);
+                                        log_error("Error parsing 'console-mode' config option, ignoring: %s",
+                                                  value);
                                         continue;
                                 }
                                 config->console_mode = u;