From: Rusty Russell <rusty@rustcorp.com.au>
I don't think it's misused anywhere, but it's better to be safe.
Pointed out by Joern Engel.
#define MTD_DEBUG_LEVEL3 (3) /* Noisy */
#ifdef CONFIG_MTD_DEBUG
-#define DEBUG(n, args...) \
- if (n <= CONFIG_MTD_DEBUG_VERBOSE) { \
- printk(KERN_INFO args); \
- }
+#define DEBUG(n, args...) \
+ do { \
+ if (n <= CONFIG_MTD_DEBUG_VERBOSE) \
+ printk(KERN_INFO args); \
+ } while(0)
#else /* CONFIG_MTD_DEBUG */
#define DEBUG(n, args...)
#endif /* CONFIG_MTD_DEBUG */