mirror of
https://xff.cz/git/u-boot/
synced 2025-09-01 16:52:14 +02:00
console: Add option to keep it silent until env is loaded
Add a config-option which forces the console to stay silent until the proper environment is loaded from flash. This is important when the default environment does not silence the console but no output must be printed when 'silent' is set in the flash environment. After the environment from flash is loaded, the console will be silenced/unsilenced depending on it. If PRE_CONSOLE_BUFFER is also used, the buffer will now be flushed if the console should not be silenced. Signed-off-by: Harald Seiler <hws@denx.de> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -970,6 +970,11 @@ static bool console_update_silent(void)
|
||||
if (!IS_ENABLED(CONFIG_SILENT_CONSOLE))
|
||||
return false;
|
||||
|
||||
if (IS_ENABLED(CONFIG_SILENT_CONSOLE_UNTIL_ENV) && !(gd->flags & GD_FLG_ENV_READY)) {
|
||||
gd->flags |= GD_FLG_SILENT;
|
||||
return false;
|
||||
}
|
||||
|
||||
if (env_get("silent")) {
|
||||
gd->flags |= GD_FLG_SILENT;
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user