diff options
author | Tom Rini <trini@konsulko.com> | 2019-02-20 12:28:40 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2019-02-20 12:28:40 -0500 |
commit | 0c41e59a37fbd5b10d4837ae30c288a084997465 (patch) | |
tree | d67fad6104715409d83073752a67cea273727249 /include/log.h | |
parent | 176b32cd4fec52307dd8234ec1c86d2f340e7a36 (diff) | |
parent | e2c901c99e2622005f98a9623c4b5339257bfad3 (diff) |
Merge git://git.denx.de/u-boot-x86
- Add support for sound.
Albeit the big changeset, changes are pretty limited to x86 only and a
few new sound drivers used by x86 so I think it would be good to have
this in the next release.
Diffstat (limited to 'include/log.h')
-rw-r--r-- | include/log.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/log.h b/include/log.h index d7f6471006..7566ba7f2d 100644 --- a/include/log.h +++ b/include/log.h @@ -14,7 +14,7 @@ /** Log levels supported, ranging from most to least important */ enum log_level_t { - LOGL_EMERG = 0, /*U-Boot is unstable */ + LOGL_EMERG = 0, /* U-Boot is unstable */ LOGL_ALERT, /* Action must be taken immediately */ LOGL_CRIT, /* Critical conditions */ LOGL_ERR, /* Error that prevents something from working */ @@ -111,11 +111,16 @@ int _log(enum log_category_t cat, enum log_level_t level, const char *file, #endif #if CONFIG_IS_ENABLED(LOG) +#ifdef LOG_DEBUG +#define _LOG_DEBUG 1 +#else +#define _LOG_DEBUG 0 +#endif /* Emit a log record if the level is less that the maximum */ #define log(_cat, _level, _fmt, _args...) ({ \ int _l = _level; \ - if (CONFIG_IS_ENABLED(LOG) && _l <= _LOG_MAX_LEVEL) \ + if (CONFIG_IS_ENABLED(LOG) && (_l <= _LOG_MAX_LEVEL || _LOG_DEBUG)) \ _log((enum log_category_t)(_cat), _l, __FILE__, __LINE__, \ __func__, \ pr_fmt(_fmt), ##_args); \ |