Skip to content
  • Dan Streetman's avatar
    Documentation: expand/clarify debug documentation · 6e099f55
    Dan Streetman authored
    
    
    The pr_debug() and related debug print macros all differ from the normal
    pr_XXX() macros, in that the normal ones print unconditionally, while
    the debug macros are compiled out unless DEBUG is defined or
    CONFIG_DYNAMIC_DEBUG is set.  This isn't obvious, and the only way to
    find this out is either to review the actual printk.h code or to read
    CodingStyle, and the message there doesn't highlight the fact.
    
    Change Documentation/CodingStyle to clearly indicate that pr_debug() and
    related debug printing macros behave differently than all other pr_XXX()
    macros, and attempt to clarify when and where the different debug
    printing methods might be used.
    
    Add short comment to printk.h above the pr_XXX() macros indicating that
    while these macros print unconditionally, pr_debug() does not.
    
    Signed-off-by: default avatarDan Streetman <ddstreet@ieee.org>
    Cc: Joe Perches <joe@perches.com>
    Cc: Fabian Frederick <fabf@skynet.be>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    6e099f55