]> pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
USB: usb.h: reduce syslog clutter [v3]
authorTilman Schmidt <tilman@imap.cc>
Thu, 13 Mar 2008 18:51:42 +0000 (19:51 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 25 Apr 2008 04:16:42 +0000 (21:16 -0700)
The the err() / info() / warn() macros in usb.h inserted __FILE__ at
the beginning of the message, which expands to the complete pathname
of the source file within the kernel tree, frequently taking up half
of an 80 character screen line before the actual message even begins.
Use the module name instead.

Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
include/linux/usb.h

index 285011d9af1746f350c0214a0315ea885e38aaea..dd9733cc0ac2c4440ed34724a60823bef24ddfe1 100644 (file)
@@ -1701,13 +1701,12 @@ extern void usb_unregister_notify(struct notifier_block *nb);
 #define dbg(format, arg...) do {} while (0)
 #endif
 
-#define err(format, arg...) printk(KERN_ERR "%s: " format "\n" , \
-       __FILE__ , ## arg)
-#define info(format, arg...) printk(KERN_INFO "%s: " format "\n" , \
-       __FILE__ , ## arg)
-#define warn(format, arg...) printk(KERN_WARNING "%s: " format "\n" , \
-       __FILE__ , ## arg)
-
+#define err(format, arg...) printk(KERN_ERR KBUILD_MODNAME ": " \
+       format "\n" , ## arg)
+#define info(format, arg...) printk(KERN_INFO KBUILD_MODNAME ": " \
+       format "\n" , ## arg)
+#define warn(format, arg...) printk(KERN_WARNING KBUILD_MODNAME ": " \
+       format "\n" , ## arg)
 
 #endif  /* __KERNEL__ */