[PATCH 2/9 V3] Add conditionalized debug() print macro.

Jon Loeliger jdl at jdl.com
Sat Sep 27 06:25:41 EST 2008


From: Jon Loeliger <jdl at freescale.com>

Signed-off-by: Jon Loeliger <jdl at freescale.com>
---
 dtc.h |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/dtc.h b/dtc.h
index 08d54c8..ec636f8 100644
--- a/dtc.h
+++ b/dtc.h
@@ -34,7 +34,15 @@
 #include <libfdt_env.h>
 #include <fdt.h>
 
+#ifdef DEBUG
+#define debug(fmt,args...)	printf(fmt, ##args)
+#else
+#define debug(fmt,args...)
+#endif
+
+
 #define DEFAULT_FDT_VERSION	17
+
 /*
  * Command line options
  */
-- 
1.6.0.90.g436ed




More information about the devicetree-discuss mailing list