summaryrefslogtreecommitdiffstats
path: root/drivers/usb/atm/usbatm.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/atm/usbatm.h')
-rw-r--r--drivers/usb/atm/usbatm.h35
1 files changed, 6 insertions, 29 deletions
diff --git a/drivers/usb/atm/usbatm.h b/drivers/usb/atm/usbatm.h
index 5fc489405217..5651231a7437 100644
--- a/drivers/usb/atm/usbatm.h
+++ b/drivers/usb/atm/usbatm.h
@@ -39,31 +39,14 @@
#define VERBOSE_DEBUG
*/
-#ifdef DEBUG
-#define UDSL_ASSERT(instance, x) BUG_ON(!(x))
-#else
-#define UDSL_ASSERT(instance, x) \
- do { \
- if (!(x)) \
- dev_warn(&(instance)->usb_intf->dev, \
- "failed assertion '%s' at line %d", \
- __stringify(x), __LINE__); \
- } while (0)
-#endif
-
#define usb_err(instance, format, arg...) \
dev_err(&(instance)->usb_intf->dev , format , ## arg)
#define usb_info(instance, format, arg...) \
dev_info(&(instance)->usb_intf->dev , format , ## arg)
#define usb_warn(instance, format, arg...) \
dev_warn(&(instance)->usb_intf->dev , format , ## arg)
-#ifdef DEBUG
-#define usb_dbg(instance, format, arg...) \
- dev_printk(KERN_DEBUG , &(instance)->usb_intf->dev , format , ## arg)
-#else
#define usb_dbg(instance, format, arg...) \
- do {} while (0)
-#endif
+ dev_dbg(&(instance)->usb_intf->dev , format , ## arg)
/* FIXME: move to dev_* once ATM is driver model aware */
#define atm_printk(level, instance, format, arg...) \
@@ -76,18 +59,12 @@
atm_printk(KERN_INFO, instance , format , ## arg)
#define atm_warn(instance, format, arg...) \
atm_printk(KERN_WARNING, instance , format , ## arg)
-#ifdef DEBUG
-#define atm_dbg(instance, format, arg...) \
- atm_printk(KERN_DEBUG, instance , format , ## arg)
-#define atm_rldbg(instance, format, arg...) \
+#define atm_dbg(instance, format, arg...) \
+ dynamic_pr_debug("ATM dev %d: " format , \
+ (instance)->atm_dev->number , ## arg)
+#define atm_rldbg(instance, format, arg...) \
if (printk_ratelimit()) \
- atm_printk(KERN_DEBUG, instance , format , ## arg)
-#else
-#define atm_dbg(instance, format, arg...) \
- do {} while (0)
-#define atm_rldbg(instance, format, arg...) \
- do {} while (0)
-#endif
+ atm_dbg(instance , format , ## arg)
/* flags, set by mini-driver in bind() */