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
2 changed files with 3 additions and 3 deletions
|
@ -170,10 +170,12 @@ void log_backend_enable(struct log_backend const *const backend,
|
||||||
void log_backend_disable(struct log_backend const *const backend);
|
void log_backend_disable(struct log_backend const *const backend);
|
||||||
|
|
||||||
#if defined(CONFIG_LOG)
|
#if defined(CONFIG_LOG)
|
||||||
|
#define LOG_CORE_INIT() log_core_init()
|
||||||
#define LOG_INIT() log_init()
|
#define LOG_INIT() log_init()
|
||||||
#define LOG_PANIC() log_panic()
|
#define LOG_PANIC() log_panic()
|
||||||
#define LOG_PROCESS() log_process(false)
|
#define LOG_PROCESS() log_process(false)
|
||||||
#else
|
#else
|
||||||
|
#define LOG_CORE_INIT() do { } while (false)
|
||||||
#define LOG_INIT() 0
|
#define LOG_INIT() 0
|
||||||
#define LOG_PANIC() /* Empty */
|
#define LOG_PANIC() /* Empty */
|
||||||
#define LOG_PROCESS() false
|
#define LOG_PROCESS() false
|
||||||
|
|
|
@ -481,9 +481,7 @@ FUNC_NORETURN void z_cstart(void)
|
||||||
/* gcov hook needed to get the coverage report.*/
|
/* gcov hook needed to get the coverage report.*/
|
||||||
gcov_static_init();
|
gcov_static_init();
|
||||||
|
|
||||||
if (IS_ENABLED(CONFIG_LOG)) {
|
LOG_CORE_INIT();
|
||||||
log_core_init();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* perform any architecture-specific initialization */
|
/* perform any architecture-specific initialization */
|
||||||
z_arch_kernel_init();
|
z_arch_kernel_init();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue