Leaked source code of windows server 2003
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.

91 lines
2.3 KiB

  1. /*++ BUILD Version: 0001 // Increment this if a change has global effects
  2. Copyright (c) 1992-1996 Microsoft Corporation
  3. Module Name:
  4. ntconreg.h
  5. Abstract:
  6. Header file for the NT Configuration Registry
  7. This file contains definitions which provide the interface to
  8. the Performance Configuration Registry.
  9. NOTE: This file is also included by other files in the regular
  10. registry support routines.
  11. Author:
  12. Russ Blake 11/15/91
  13. Revision History:
  14. 04/20/91 - russbl - Converted to lib in Registry
  15. from stand-alone .dll form.
  16. 11/04/92 - a-robw - added pagefile counters
  17. --*/
  18. //
  19. #include <winperf.h> // for fn prototype declarations
  20. #include <ntddnfs.h>
  21. #include <srvfsctl.h>
  22. #include <assert.h>
  23. //
  24. // Until USER supports Unicode, we have to work in ASCII:
  25. //
  26. #define DEFAULT_NT_CODE_PAGE 437
  27. #define UNICODE_CODE_PAGE 0
  28. //
  29. // Utility macro. This is used to reserve a DWORD multiple of
  30. // bytes for Unicode strings embedded in the definitional data,
  31. // viz., object instance names.
  32. //
  33. // Assumes x is DWORD, and returns a DWORD
  34. //
  35. #define DWORD_MULTIPLE(x) (((ULONG)(x) + ((4)-1)) & ~((ULONG)(4)-1))
  36. #define QWORD_MULTIPLE(x) (((ULONG)(x) + ((8)-1)) & ~((ULONG)(8)-1))
  37. //
  38. // Returns a PVOID
  39. //
  40. #define ALIGN_ON_DWORD(x) \
  41. ((VOID *)(((ULONG_PTR)(x) + ((4)-1)) & ~((ULONG_PTR)(4)-1)))
  42. #define ALIGN_ON_QWORD(x) \
  43. ((VOID *)(((ULONG_PTR)(x) + ((8)-1)) & ~((ULONG_PTR)(8)-1)))
  44. //
  45. // Definitions for internal use by the Performance Configuration Registry
  46. //
  47. // They have been moved to perfdlls and perflib.h and left here
  48. // for references only
  49. //
  50. // #define NUM_VALUES 2
  51. // #define MAX_INSTANCE_NAME 32
  52. // #define DEFAULT_LARGE_BUFFER 8*1024
  53. // #define INCREMENT_BUFFER_SIZE 4*1024
  54. // #define MAX_PROCESS_NAME_LENGTH 256*sizeof(WCHAR)
  55. // #define MAX_THREAD_NAME_LENGTH 10*sizeof(WCHAR)
  56. // #define MAX_KEY_NAME_LENGTH 256*sizeof(WCHAR)
  57. // #define MAX_VALUE_NAME_LENGTH 256*sizeof(WCHAR)
  58. // #define MAX_VALUE_DATA_LENGTH 256*sizeof(WCHAR)
  59. typedef PM_OPEN_PROC *OPENPROC;
  60. typedef PM_COLLECT_PROC *COLLECTPROC;
  61. typedef PM_QUERY_PROC *QUERYPROC;
  62. typedef PM_CLOSE_PROC *CLOSEPROC;
  63. DWORD
  64. PerfOpenKey (
  65. IN HKEY hKey
  66. );
  67. BOOL
  68. PerfRegInitialize ();
  69. BOOL
  70. PerfRegCleanup ();