Skip to content

Commit 36776b7

Browse files
geertupmladek
authored andcommitted
lib/hexdump: print_hex_dump_bytes() calls print_hex_dump_debug()
print_hex_dump_bytes() claims to be a simple wrapper around print_hex_dump(), but it actally calls print_hex_dump_debug(), which means no output is printed if (dynamic) DEBUG is disabled. Update the documentation to match the implementation. Fixes: 091cb09 ("lib/hexdump: make print_hex_dump_bytes() a nop on !DEBUG builds") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Petr Mladek <pmladek@suse.com> Link: https://patch.msgid.link/3d5c3069fd9102ecaf81d044b750cd613eb72a08.1774970392.git.geert+renesas@glider.be Signed-off-by: Petr Mladek <pmladek@suse.com>
1 parent f4cf099 commit 36776b7

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

include/linux/printk.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -803,15 +803,16 @@ static inline void print_hex_dump_debug(const char *prefix_str, int prefix_type,
803803
#endif
804804

805805
/**
806-
* print_hex_dump_bytes - shorthand form of print_hex_dump() with default params
806+
* print_hex_dump_bytes - shorthand form of print_hex_dump_debug() with default
807+
* params
807808
* @prefix_str: string to prefix each line with;
808809
* caller supplies trailing spaces for alignment if desired
809810
* @prefix_type: controls whether prefix of an offset, address, or none
810811
* is printed (%DUMP_PREFIX_OFFSET, %DUMP_PREFIX_ADDRESS, %DUMP_PREFIX_NONE)
811812
* @buf: data blob to dump
812813
* @len: number of bytes in the @buf
813814
*
814-
* Calls print_hex_dump(), with log level of KERN_DEBUG,
815+
* Calls print_hex_dump_debug(), with log level of KERN_DEBUG,
815816
* rowsize of 16, groupsize of 1, and ASCII output included.
816817
*/
817818
#define print_hex_dump_bytes(prefix_str, prefix_type, buf, len) \

0 commit comments

Comments
 (0)