From 2937aaaaf09c2f0d5b46b1a2a30eac962d8455d3 Mon Sep 17 00:00:00 2001 From: patacongo Date: Fri, 23 Nov 2007 22:32:52 +0000 Subject: Debug can now be selectively enabled by subystem git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@404 42af7a65-404d-4744-a932-0658087f49c3 --- nuttx/include/debug.h | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'nuttx/include/debug.h') diff --git a/nuttx/include/debug.h b/nuttx/include/debug.h index 2055fb9db..38ec57ba2 100644 --- a/nuttx/include/debug.h +++ b/nuttx/include/debug.h @@ -80,6 +80,38 @@ # define vdbg(x...) #endif +/* Subsystem specific debug */ + +#ifdef CONFIG_DEBUG_MM +# define mdbg(format, arg...) dbg(format, ##arg) +# define mlldbg(format, arg...) lldbg(format, ##arg) +# define mvdbg(format, arg...) vdbg(format, ##arg) +#else +# define mdbg(x...) +# define mlldbg(x...) +# define mvdbg(x...) +#endif + +#ifdef CONFIG_DEBUG_SCHED +# define sdbg(format, arg...) dbg(format, ##arg) +# define slldbg(format, arg...) lldbg(format, ##arg) +# define svdbg(format, arg...) vdbg(format, ##arg) +#else +# define sdbg(x...) +# define slldbg(x...) +# define svdbg(x...) +#endif + +#ifdef CONFIG_DEBUG_NET +# define ndbg(format, arg...) dbg(format, ##arg) +# define nlldbg(format, arg...) lldbg(format, ##arg) +# define nvdbg(format, arg...) vdbg(format, ##arg) +#else +# define ndbg(x...) +# define nlldbg(x...) +# define nvdbg(x...) +#endif + /************************************************************ * Public Type Declarations ************************************************************/ -- cgit v1.2.3