diff options
author | Greg Banks <gnb@sgi.com> | 2009-03-11 06:07:28 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-03-24 19:38:27 -0400 |
commit | e6e66b02e11563abdb7f69dcb7a2efbd8d577e77 (patch) | |
tree | db93d906bbe7a9b93dce80b8d67341ecad473fa4 /include/linux/dynamic_debug.h | |
parent | 9898abb3d23311fa227a7f46bf4e40fd2954057f (diff) |
Dynamic debug: fix pr_fmt() build error
When CONFIG_DYNAMIC_DEBUG is enabled, allow callers of pr_debug()
to provide their own definition of pr_fmt() even if that definition
uses tricks like
#define pr_fmt(fmt) "%s:" fmt, __func__
Signed-off-by: Greg Banks <gnb@sgi.com>
Cc: Jason Baron <jbaron@redhat.com>
Acked-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include/linux/dynamic_debug.h')
-rw-r--r-- | include/linux/dynamic_debug.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h index 07781aaa1164..baabf33be244 100644 --- a/include/linux/dynamic_debug.h +++ b/include/linux/dynamic_debug.h | |||
@@ -57,7 +57,7 @@ extern int ddebug_remove_module(char *mod_name); | |||
57 | { KBUILD_MODNAME, __func__, __FILE__, fmt, DEBUG_HASH, \ | 57 | { KBUILD_MODNAME, __func__, __FILE__, fmt, DEBUG_HASH, \ |
58 | DEBUG_HASH2, __LINE__, _DPRINTK_FLAGS_DEFAULT }; \ | 58 | DEBUG_HASH2, __LINE__, _DPRINTK_FLAGS_DEFAULT }; \ |
59 | if (__dynamic_dbg_enabled(descriptor)) \ | 59 | if (__dynamic_dbg_enabled(descriptor)) \ |
60 | printk(KERN_DEBUG KBUILD_MODNAME ":" fmt, \ | 60 | printk(KERN_DEBUG KBUILD_MODNAME ":" pr_fmt(fmt), \ |
61 | ##__VA_ARGS__); \ | 61 | ##__VA_ARGS__); \ |
62 | } while (0) | 62 | } while (0) |
63 | 63 | ||
@@ -70,7 +70,7 @@ extern int ddebug_remove_module(char *mod_name); | |||
70 | DEBUG_HASH2, __LINE__, _DPRINTK_FLAGS_DEFAULT }; \ | 70 | DEBUG_HASH2, __LINE__, _DPRINTK_FLAGS_DEFAULT }; \ |
71 | if (__dynamic_dbg_enabled(descriptor)) \ | 71 | if (__dynamic_dbg_enabled(descriptor)) \ |
72 | dev_printk(KERN_DEBUG, dev, \ | 72 | dev_printk(KERN_DEBUG, dev, \ |
73 | KBUILD_MODNAME ": " fmt, \ | 73 | KBUILD_MODNAME ": " pr_fmt(fmt),\ |
74 | ##__VA_ARGS__); \ | 74 | ##__VA_ARGS__); \ |
75 | } while (0) | 75 | } while (0) |
76 | 76 | ||