Skip to content

Commit 568c09c

Browse files
io-amperecfriedt
authored andcommitted
log_core: Add Kconfig symbol for init priority
Users may want to do some configuration after the kernel is up, but before initializing the log_core. Making the log_core's init priority configurable makes that possible. Signed-off-by: Ian Oliver <[email protected]> (cherry picked from commit 1675d49)
1 parent 79f6c53 commit 568c09c

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

subsys/logging/Kconfig

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@ menuconfig LOG
1010

1111
if LOG
1212

13+
config LOG_CORE_INIT_PRIORITY
14+
int "Log Core Initialization Priority"
15+
range 0 99
16+
default 0
17+
1318
rsource "Kconfig.mode"
1419

1520
rsource "Kconfig.filtering"

subsys/logging/log_core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1276,4 +1276,4 @@ static int enable_logger(const struct device *arg)
12761276
return 0;
12771277
}
12781278

1279-
SYS_INIT(enable_logger, POST_KERNEL, 0);
1279+
SYS_INIT(enable_logger, POST_KERNEL, CONFIG_LOG_CORE_INIT_PRIORITY);

0 commit comments

Comments
 (0)