mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-21 14:41:31 +00:00
Add comments for debug() and pr_fmt
Add a note to each of these so it is more obvious how they work. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
6b424611a8
commit
5e7f743324
1 changed files with 2 additions and 0 deletions
|
@ -101,6 +101,7 @@ typedef volatile unsigned char vu_char;
|
|||
#define _DEBUG 0
|
||||
#endif
|
||||
|
||||
/* Define this at the top of a file to add a prefix to debug messages */
|
||||
#ifndef pr_fmt
|
||||
#define pr_fmt(fmt) fmt
|
||||
#endif
|
||||
|
@ -116,6 +117,7 @@ typedef volatile unsigned char vu_char;
|
|||
printf(pr_fmt(fmt), ##args); \
|
||||
} while (0)
|
||||
|
||||
/* Show a message if DEBUG is defined in a file */
|
||||
#define debug(fmt, args...) \
|
||||
debug_cond(_DEBUG, fmt, ##args)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue