diff options
Diffstat (limited to 'pdl/include/pdl_debug.h')
-rw-r--r-- | pdl/include/pdl_debug.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/pdl/include/pdl_debug.h b/pdl/include/pdl_debug.h new file mode 100644 index 0000000000..d908e7a28f --- /dev/null +++ b/pdl/include/pdl_debug.h @@ -0,0 +1,28 @@ +#ifndef _PDL_DEBUG_H_ +#define _PDL_DEBUG_H_ + +#include <serial.h> + +#define PDL_LOG_MAX_SIZE (512*1024) + +extern char *pdl_log_buff; +void pdl_init_serial(void); +void pdl_release_serial(void); + +#define pdl_error printf +#define pdl_info printf + +extern int pdl_dbg_pdl; +#define pdl_dbg(str...) \ + do { \ + if (pdl_dbg_pdl) \ + printf(str); \ + } while(0) + +extern int pdl_vdbg_pdl; +#define pdl_vdbg(str...) \ + do { \ + if (pdl_vdbg_pdl) \ + printf(str); \ + } while(0) +#endif |