logging: abstract log_core_init()
Similar to how LOG_INIT(), LOG_PANIC(), etc are wrapped. Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
parent
56650aff7e
commit
144f2cb2b3
|
@ -170,10 +170,12 @@ void log_backend_enable(struct log_backend const *const backend,
|
|||
void log_backend_disable(struct log_backend const *const backend);
|
||||
|
||||
#if defined(CONFIG_LOG)
|
||||
#define LOG_CORE_INIT() log_core_init()
|
||||
#define LOG_INIT() log_init()
|
||||
#define LOG_PANIC() log_panic()
|
||||
#define LOG_PROCESS() log_process(false)
|
||||
#else
|
||||
#define LOG_CORE_INIT() do { } while (false)
|
||||
#define LOG_INIT() 0
|
||||
#define LOG_PANIC() /* Empty */
|
||||
#define LOG_PROCESS() false
|
||||
|
|
|
@ -481,9 +481,7 @@ FUNC_NORETURN void z_cstart(void)
|
|||
/* gcov hook needed to get the coverage report.*/
|
||||
gcov_static_init();
|
||||
|
||||
if (IS_ENABLED(CONFIG_LOG)) {
|
||||
log_core_init();
|
||||
}
|
||||
LOG_CORE_INIT();
|
||||
|
||||
/* perform any architecture-specific initialization */
|
||||
z_arch_kernel_init();
|
||||
|
|
Loading…
Reference in a new issue