Skip to content
Commit e83f88b9 authored by Marco Widmer's avatar Marco Widmer Committed by Alberto Escolar
Browse files

logging: use runtime message creation when logging is disabled



If compiler optimizations are disabled, some compilers (especially
arm_cortex_m) are using unrealistic amounts of stack for dead code.
Currently, if CONFIG_LOG=y and CONFIG_NO_OPTIMIZATIONS=y,
CONFIG_LOG_ALWAYS_RUNTIME is enabled to reduce the stack used by the
logging code.
However, if CONFIG_LOG=n, CONFIG_LOG_ALWAYS_RUNTIME is not available
which causes the compiler to allocate lots of stack space for the (dead)
logging code.
This patch forces runtime message creation when CONFIG_LOG=n. Since all
logging code is dead code when logging is disabled, the behavior should
be unchanged.

Signed-off-by: default avatarMarco Widmer <marco.widmer@bytesatwork.ch>
parent 239c20d2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment