mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-06-27 09:02:20 +00:00
sandbox: Add a flag to set the default log level
It is useful to be able to set the default log level from the command line when running sandbox. Add a new -L command-line flag for this. The log level is set using the enum log_level_t in log.h. At present a number must be specified, e.g. -L7 for debug. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
69bc15d5ff
commit
2b1dc29a12
3 changed files with 16 additions and 1 deletions
|
@ -315,7 +315,8 @@ int log_init(void)
|
|||
drv++;
|
||||
}
|
||||
gd->flags |= GD_FLG_LOG_READY;
|
||||
gd->default_log_level = LOGL_INFO;
|
||||
if (!gd->default_log_level)
|
||||
gd->default_log_level = LOGL_INFO;
|
||||
gd->log_fmt = LOGF_DEFAULT;
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue