Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
942 B

  1. /*++
  2. Copyright (c) 1991 Microsoft Corporation
  3. Module Name:
  4. dlcdebug.h
  5. Abstract:
  6. Contains various debugging/diagnostic stuff for DLC.SYS, checked
  7. Author:
  8. Richard L Firth (rfirth) 25-Jun-1992
  9. Revision History:
  10. --*/
  11. #if DBG
  12. #ifdef DEFINE_DLC_DIAGNOSTICS
  13. //
  14. // we can preset the diagnostics at compile-time by defining DEFAULT_DIAGNOSTICS
  15. //
  16. #ifndef DEFAULT_DIAGNOSTICS
  17. #define DEFAULT_DIAGNOSTICS 0
  18. #endif
  19. ULONG DlcDiagnostics = DEFAULT_DIAGNOSTICS;
  20. #else
  21. extern ULONG DlcDiagnostics;
  22. #endif
  23. #define DIAG_FUNCTION_NAME 0x00000001
  24. #define DIAG_MDL_ALLOC 0x00000002
  25. #define DIAG_DEVICE_IO 0x00000004
  26. #define IF_DIAG(p) if (DlcDiagnostics & DIAG_ ## p)
  27. #define DIAG_FUNCTION(s) IF_DIAG(FUNCTION_NAME) { \
  28. DbgPrint(s "\n"); \
  29. }
  30. #else
  31. #define IF_DIAG(p) if (0)
  32. #define DIAG_FUNCTION(s) if (0) {(void)(s);}
  33. #endif