vconsole-setup: reword error messages

I was looking at some logs, and — without context —
"Setting source virtual console failed" doesn't make sense. It's a source
internally in vconsole-setup because we configure it and then use it to copy
the settings to other consoles. But at the point this message is emitted it's
not yet a source of anything. Also, "setting" sounds like we'd like to assign
it somewhere, which is even more confusing. Reword the messages to be more
down-to-earth and meaningful without looking at the code.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2025-03-25 10:17:05 +01:00
parent c4876f604b
commit 6ba1ee5c7d
+3 -3
View File
@@ -607,7 +607,7 @@ static int run(int argc, char **argv) {
} else {
fd = find_source_vc(&vc, &idx);
if (fd < 0 && fd != -EBUSY)
return log_error_errno(fd, "No usable source console found: %m");
return log_error_errno(fd, "No virtual console that can be configured found: %m");
}
utf8 = is_locale_utf8();
@@ -617,7 +617,7 @@ static int run(int argc, char **argv) {
/* We found only busy VCs, which might happen during the boot process when the boot splash is
* displayed on the only allocated VC. In this case we don't interfere and avoid initializing
* the VC partially as some operations are likely to fail. */
log_notice("All allocated VCs are currently busy, skipping initialization of font and keyboard settings.");
log_notice("All allocated virtual consoles are busy, will not configure key mapping and font.");
return EXIT_SUCCESS;
}
@@ -641,7 +641,7 @@ static int run(int argc, char **argv) {
setup_remaining_vcs(fd, idx, utf8);
else
log_full(r == EX_OSERR ? LOG_NOTICE : LOG_WARNING,
"Setting source virtual console failed, ignoring remaining ones.");
"Configuration of first virtual console failed, ignoring remaining ones.");
}
return IN_SET(r, 0, EX_OSERR) && keyboard_ok ? EXIT_SUCCESS : EXIT_FAILURE;