source: rtems/c/src/lib/libbsp/sparc/shared/include/debug_defs.h @ e16e0ca

4.104.114.84.95
Last change on this file since e16e0ca was e16e0ca, checked in by Joel Sherrill <joel.sherrill@…>, on Sep 6, 2007 at 1:25:42 PM

2007-09-06 Daniel Hellstrom <daniel@…>

  • Makefile.am: Add the following new drivers: PCI, b1553BRM, SpaceWire?(GRSPW), CAN (GRCAN,OC_CAN), Raw UART.
  • shared/include/apbuart.h, shared/include/apbuart_pci.h, shared/include/apbuart_rasta.h, shared/include/b1553brm.h, shared/include/b1553brm_pci.h, shared/include/b1553brm_rasta.h, shared/include/debug_defs.h, shared/include/grcan.h, shared/include/grcan_rasta.h, shared/include/grcan_spwrtc.h, shared/include/grspw.h, shared/include/grspw_pci.h, shared/include/grspw_rasta.h, shared/include/occan.h, shared/include/occan_pci.h, shared/include/pci.h: New files.
  • Property mode set to 100644
File size: 903 bytes
Line 
1
2#ifndef __DEBUG_DEFS_H__
3#define __DEBUG_DEFS_H__
4
5#ifdef __cplusplus
6extern "C" {
7#endif
8
9
10#ifdef DEBUG
11
12 #ifndef DEBUG_FLAGS
13  #define DEBUG_FLAGS 0
14 #endif
15
16 extern int DEBUG_printf(const char *fmt, ...);
17 #define DBG(fmt, args...)    do { printk(" : %03d @ %18s()]:" fmt , __LINE__,__FUNCTION__,## args); } while(0)
18 #define DBG2(fmt)            do { printk(" : %03d @ %18s()]:" fmt , __LINE__,__FUNCTION__); } while(0)
19 #define DBGC(c,fmt, args...) do { if (DEBUG_FLAGS & c) { printk(" : %03d @ %18s()]:" fmt , __LINE__,__FUNCTION__,## args);  }} while(0)
20
21#else
22
23 #define DBG(fmt, args...)
24 #define DBG2(fmt, args...)
25 #define DBGC(c, fmt, args...)
26 
27#endif
28
29#ifdef DEBUGFUNCS
30  #define FUNCDBG()         do { printk("%s\n\r",__FUNCTION__); } while(0)
31  extern int DEBUG_printf(const char *fmt, ...);
32#else
33  #define FUNCDBG()
34#endif
35
36#ifdef __cplusplus
37}
38#endif
39
40#endif /* __DEBUG_DEFS_H__ */
Note: See TracBrowser for help on using the repository browser.