rk30: clock: better support log
author黄涛 <huangtao@rock-chips.com>
Fri, 11 May 2012 09:46:50 +0000 (17:46 +0800)
committer黄涛 <huangtao@rock-chips.com>
Fri, 11 May 2012 09:47:31 +0000 (17:47 +0800)
arch/arm/mach-rk30/clock_data.c

index b14cb09290721424d6d579fb3ea39f425c85afee..79d728e57d877dde39b939f9e244d4b2d5865539 100644 (file)
@@ -175,10 +175,14 @@ void rk30_clkdev_add(struct clk_lookup *cl);
 #define cru_writel_frac(v,offset) cru_writel((v),(offset))
 #endif
 
-
-#define CRU_PRINTK_DBG(fmt, args...) {while(0);}//pr_debug(fmt, ## args);
-#define CRU_PRINTK_ERR(fmt, args...) pr_err(fmt, ## args);
-#define CRU_PRINTK_LOG(fmt, args...) pr_debug(fmt, ## args);
+#ifdef DEBUG
+#define CRU_PRINTK_DBG(fmt, args...) pr_debug(fmt, ## args)
+#define CRU_PRINTK_LOG(fmt, args...) pr_debug(fmt, ## args)
+#else
+#define CRU_PRINTK_DBG(fmt, args...) do {} while(0)
+#define CRU_PRINTK_LOG(fmt, args...) do {} while(0)
+#endif
+#define CRU_PRINTK_ERR(fmt, args...) pr_err(fmt, ## args)
 
 
 #define get_cru_bits(con,mask,shift)\