summaryrefslogtreecommitdiff
path: root/common/log_console.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-09-12 21:28:47 +0300
committerTom Rini <trini@konsulko.com>2020-10-10 23:50:11 +0300
commitb45203004ec3f3e5a259e68eddb3eb572d37f56d (patch)
treeb43d3a931abfa4e558aca75872952402f0a8adfb /common/log_console.c
parent26637e2e4c7235e4fe01b78a9646471c65e28aea (diff)
downloadu-boot-b45203004ec3f3e5a259e68eddb3eb572d37f56d.tar.xz
log: Add a flag to enable log drivers
At present there is no way to disable a log driver. But the syslog driver causes (attempted) network traffic in sandbox every time a log message is printed, which is often. Add a flag to enable a log driver. Adjust struct log_device to use a short for next_filter_num so that no more memory is used for devices. Also fix a missing line in the struct log_driver comment while here. To maintain compatibility, enable it for all drivers for now. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common/log_console.c')
-rw-r--r--common/log_console.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/common/log_console.c b/common/log_console.c
index bb3f8464b9..8776fd4703 100644
--- a/common/log_console.c
+++ b/common/log_console.c
@@ -44,4 +44,5 @@ static int log_console_emit(struct log_device *ldev, struct log_rec *rec)
LOG_DRIVER(console) = {
.name = "console",
.emit = log_console_emit,
+ .flags = LOGDF_ENABLE,
};