[PATCH 0/4] log: Fix the syslog spam when running tests

Simon Glass sjg at chromium.org
Sat Sep 12 20:28:46 CEST 2020


At present running some sandbox tests produces unwanted ethernet errors
from the syslog driver, e.g.:

$ ./u-boot -c "ut bloblist"

Running 5 bloblist tests
Test: bloblist_test_bad_blob
Test: bloblist_test_blob
Test: bloblist_test_blob_ensure
Failed to allocate e0 bytes size=100, need size=130
No ethernet found.
bloblist add: returning err=-28
No ethernet found.
Test: bloblist_test_checksum
Checksum f3129fae != 338fbdc
No ethernet found.
Bad checksum: returning err=-5
No ethernet found.
...

This series fixes this by making the syslog driver disabled by default. It
can be enabled with a function call.


Simon Glass (4):
  log: Add a flag to enable log drivers
  log: Drop #ifdef in log_test
  log: Add a way to enable/disable a log device
  log: Disable the syslog driver by default

 common/log.c                  | 42 ++++++++++++++++++++++++++++++++++-
 common/log_console.c          |  1 +
 include/log.h                 | 28 ++++++++++++++++++++++-
 test/log/log_test.c           |  9 ++++++--
 test/log/syslog_test.c        | 24 ++++++++++++++++++++
 test/log/syslog_test.h        | 16 +++++++++++++
 test/log/syslog_test_ndebug.c |  2 ++
 test/py/tests/test_log.py     |  8 +++++++
 8 files changed, 126 insertions(+), 4 deletions(-)

-- 
2.28.0.618.gf4bc123cb7-goog



More information about the U-Boot mailing list