aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/misc/legousbtower.c
diff options
context:
space:
mode:
authorAndrea Bastoni <bastoni@cs.unc.edu>2010-05-30 19:16:45 -0400
committerAndrea Bastoni <bastoni@cs.unc.edu>2010-05-30 19:16:45 -0400
commitada47b5fe13d89735805b566185f4885f5a3f750 (patch)
tree644b88f8a71896307d71438e9b3af49126ffb22b /drivers/usb/misc/legousbtower.c
parent43e98717ad40a4ae64545b5ba047c7b86aa44f4f (diff)
parent3280f21d43ee541f97f8cda5792150d2dbec20d5 (diff)
Merge branch 'wip-2.6.34' into old-private-masterarchived-private-master
Diffstat (limited to 'drivers/usb/misc/legousbtower.c')
-rw-r--r--drivers/usb/misc/legousbtower.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/usb/misc/legousbtower.c b/drivers/usb/misc/legousbtower.c
index faa6d623de78..8547bf9e3175 100644
--- a/drivers/usb/misc/legousbtower.c
+++ b/drivers/usb/misc/legousbtower.c
@@ -95,8 +95,11 @@
95 95
96/* Use our own dbg macro */ 96/* Use our own dbg macro */
97#undef dbg 97#undef dbg
98#define dbg(lvl, format, arg...) do { if (debug >= lvl) printk(KERN_DEBUG __FILE__ ": " format "\n", ## arg); } while (0) 98#define dbg(lvl, format, arg...) \
99 99do { \
100 if (debug >= lvl) \
101 printk(KERN_DEBUG "%s: " format "\n", __FILE__, ##arg); \
102} while (0)
100 103
101/* Version Information */ 104/* Version Information */
102#define DRIVER_VERSION "v0.96" 105#define DRIVER_VERSION "v0.96"
@@ -192,7 +195,7 @@ struct tower_get_version_reply {
192 195
193 196
194/* table of devices that work with this driver */ 197/* table of devices that work with this driver */
195static struct usb_device_id tower_table [] = { 198static const struct usb_device_id tower_table[] = {
196 { USB_DEVICE(LEGO_USB_TOWER_VENDOR_ID, LEGO_USB_TOWER_PRODUCT_ID) }, 199 { USB_DEVICE(LEGO_USB_TOWER_VENDOR_ID, LEGO_USB_TOWER_PRODUCT_ID) },
197 { } /* Terminating entry */ 200 { } /* Terminating entry */
198}; 201};
@@ -302,7 +305,7 @@ static inline void lego_usb_tower_debug_data (int level, const char *function, i
302 if (debug < level) 305 if (debug < level)
303 return; 306 return;
304 307
305 printk (KERN_DEBUG __FILE__": %s - length = %d, data = ", function, size); 308 printk (KERN_DEBUG "%s: %s - length = %d, data = ", __FILE__, function, size);
306 for (i = 0; i < size; ++i) { 309 for (i = 0; i < size; ++i) {
307 printk ("%.2x ", data[i]); 310 printk ("%.2x ", data[i]);
308 } 311 }
@@ -1055,7 +1058,7 @@ static int __init lego_usb_tower_init(void)
1055 /* register this driver with the USB subsystem */ 1058 /* register this driver with the USB subsystem */
1056 result = usb_register(&tower_driver); 1059 result = usb_register(&tower_driver);
1057 if (result < 0) { 1060 if (result < 0) {
1058 err("usb_register failed for the "__FILE__" driver. Error number %d", result); 1061 err("usb_register failed for the %s driver. Error number %d", __FILE__, result);
1059 retval = -1; 1062 retval = -1;
1060 goto exit; 1063 goto exit;
1061 } 1064 }