diff options
| author | Tom Rini <[email protected]> | 2022-07-27 06:59:55 -0400 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2022-07-27 06:59:55 -0400 |
| commit | 7277c4bddceb6b8a59ba47b8b111ab070d86919f (patch) | |
| tree | 0bd1db6551763d178d25e80a350be458150c9e8e /doc/develop | |
| parent | 81e712a91729950fbd8fb38a6f729cb9847b0adb (diff) | |
| parent | dce4322c0e1940e11ef9ff086890b8c474707317 (diff) | |
Merge tag 'dm-pull-26jul22' of https://gitlab.denx.de/u-boot/custodians/u-boot-dm.git
minor dm- and fdt-related fixes
start of test for fdt command
Diffstat (limited to 'doc/develop')
| -rw-r--r-- | doc/develop/logging.rst | 19 |
1 files changed, 7 insertions, 12 deletions
diff --git a/doc/develop/logging.rst b/doc/develop/logging.rst index 51095b05ba9..704a6bf1d84 100644 --- a/doc/develop/logging.rst +++ b/doc/develop/logging.rst @@ -66,26 +66,21 @@ Sometimes it is useful to turn on logging just in one file. You can use this #define LOG_DEBUG to enable building in of all logging statements in a single file. Put it at -the top of the file, before any #includes. - -To actually get U-Boot to output this you need to also set the default logging -level - e.g. set CONFIG_LOG_DEFAULT_LEVEL to 7 (:c:data:`LOGL_DEBUG`) or more. -Otherwise debug output is suppressed and will not be generated. +the top of the file, before any #includes and any message in the file will be +written, regardless of the value of CONFIG_LOG_DEFAULT_LEVEL. Using DEBUG ----------- U-Boot has traditionally used a #define called DEBUG to enable debugging on a -file-by-file basis. The debug() macro compiles to a printf() statement if -DEBUG is enabled, and an empty statement if not. +file-by-file basis but LOG_DEBUG are intended to replace it with the logging +facilities; DEBUG is activated when LOG_DEBUG is activated. With logging enabled, debug() statements are interpreted as logging output -with a level of LOGL_DEBUG and a category of LOGC_NONE. +with a level of LOGL_DEBUG and a category of LOG_CATEGORY. -The logging facilities are intended to replace DEBUG, but if DEBUG is defined -at the top of a file, then it takes precedence. This means that debug() -statements will result in output to the console and this output will not be -logged. +With logging disabled, the debug() macro compiles to a printf() statement +if DEBUG is enabled and to an empty statement if not. Logging statements ------------------ |
