u_boot_pylib: Support a fatal level in tout
It is convenient to be able to print a message and exit. Add a new
'fatal' level to support this.
Update some assumptions about the level, so that the tools continue to
work as now.
Signed-off-by: Simon Glass <sjg@chromium.org>
diff --git a/tools/binman/control.py b/tools/binman/control.py
index 81f61e3..1946656 100644
--- a/tools/binman/control.py
+++ b/tools/binman/control.py
@@ -777,7 +777,7 @@
if args.cmd in ['ls', 'extract', 'replace', 'tool', 'sign']:
try:
- tout.init(args.verbosity)
+ tout.init(args.verbosity + 1)
if args.cmd == 'replace':
tools.prepare_output_dir(args.outdir, args.preserve)
else:
@@ -835,9 +835,9 @@
args.indir.append(board_pathname)
try:
- tout.init(args.verbosity)
+ tout.init(args.verbosity + 1)
elf.debug = args.debug
- cbfs_util.VERBOSE = args.verbosity > 2
+ cbfs_util.VERBOSE = args.verbosity > tout.NOTICE
state.use_fake_dtb = args.fake_dtb
# Normally we replace the 'u-boot' etype with 'u-boot-expanded', etc.