logging: Refactor LOG_MODULE_REGISTER and LOG_MODULE_DECLARE macros

Changed LOG_MODULE_REGISTER and LOG_MODULE_DECLARE macros to take log
level as optional parameter. LOG_MODULE_DECLARE can now also be used
in static inline functions in headers. Added LOG_LEVEL_SET macro
which is used when instance logging API is used to indicate maximal
log level compiled into the file.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
This commit is contained in:
Krzysztof Chruscinski 2018-09-25 14:58:27 +02:00 committed by Anas Nashif
commit 5e346812ac
13 changed files with 223 additions and 104 deletions

View file

@ -9,5 +9,9 @@ config PM_CONTROL_OS_DEBUG
help
Enable OS Power Management debugging hooks.
module = PM
module-str = Power Management
source "subsys/logging/Kconfig.template.log_config"
endmenu
endif # PM_CONTROL_OS