Skip to content

Commit 73d19ac

Browse files
nordic-krchkartben
authored andcommitted
debug: cpu_load: Add configurable log level
Add Kconfig for configuring cpu_load log level. Signed-off-by: Krzysztof Chruściński <[email protected]>
1 parent 97f2814 commit 73d19ac

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

subsys/debug/Kconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -357,3 +357,7 @@ config CPU_LOAD_LOG_PERIODICALLY
357357
default 0
358358
help
359359
Specifies how often CPU load shall be logged. 0 means that there is no logging.
360+
361+
module = CPU_LOAD
362+
module-str = cpu_load
363+
source "subsys/logging/Kconfig.template.log_config"

subsys/debug/cpu_load.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#include <zephyr/kernel.h>
99
#include <zephyr/drivers/counter.h>
1010
#include <zephyr/logging/log.h>
11-
LOG_MODULE_REGISTER(cpu_load);
11+
LOG_MODULE_REGISTER(cpu_load, CONFIG_CPU_LOAD_LOG_LEVEL);
1212

1313
BUILD_ASSERT(!IS_ENABLED(CONFIG_CPU_LOAD_USE_COUNTER) || DT_HAS_CHOSEN(zephyr_cpu_load_counter));
1414

0 commit comments

Comments
 (0)