hdmi_dbg.h 869 B

12345678910111213141516171819202122232425262728
  1. #ifndef __HDMI_DBG_H__
  2. #define __HDMI_DBG_H__
  3. #include "drv_types.h"
  4. #include <drv_debug.h>
  5. #include <linux/kernel.h> /* printk */
  6. #define bHDMIDBG ((*(UINT32*)DBGCONFIG1ADDR)&DBGCFG_HDMI)
  7. #define bSwitchDBG ((*(UINT32*)DBGCONFIG2ADDR)&DBGCFG_CECSWITCH)
  8. #define bCECDBG ((*(UINT32*)DBGCONFIG1ADDR)&DBGCFG_CEC)
  9. //#define bHDMIDBG 1
  10. //#define bSwitchDBG 1
  11. //#define bCECDBG 1
  12. #ifdef __KERNEL__
  13. #ifndef CONFIG_SUPPORT_DEBUG_MESSAGE
  14. #define hdmidbg(fmt,args...)
  15. #define switchdbg(fmt,args...)
  16. #define cecdbg(fmt,args...)
  17. #else
  18. #define hdmidbg(fmt,args...) do{ if (bHDMIDBG) printk("[H] " fmt, ## args); } while(0)
  19. #define switchdbg(fmt,args...) do{ if (bSwitchDBG) printk("[HS] " fmt, ## args); } while(0)
  20. #define cecdbg(fmt,args...) do{ if (bCECDBG) printk("[CEC] " fmt, ## args); } while(0)
  21. #endif
  22. #endif
  23. #endif /* __HDMI_DBG_H__ */