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.

141 lines
2.4 KiB

  1. /*++
  2. Copyright (c) 1996-1998 Microsoft Corporation
  3. Module Name:
  4. cldskwmi.c
  5. Abstract:
  6. km wmi tracing code.
  7. Will be shared between our drivers.
  8. Authors:
  9. GorN 10-Aug-1999
  10. Environment:
  11. kernel mode only
  12. Notes:
  13. Revision History:
  14. Comments:
  15. This code is a quick hack to enable WMI tracing in cluster drivers.
  16. It should eventually go away.
  17. WmlTinySystemControl will be replaced with WmilibSystemControl from wmilib.sys .
  18. WmlTrace or equivalent will be added to the kernel in addition to IoWMIWriteEvent(&TraceBuffer);
  19. --*/
  20. #include "precomp.h"
  21. #pragma hdrstop
  22. //#include <ntos.h>
  23. //#include <ntrtl.h>
  24. //#include <nturtl.h>
  25. // #include <wmistr.h>
  26. // #include <evntrace.h>
  27. // #include "wmlkm.h"
  28. BOOLEAN
  29. WmlpFindGuid(
  30. IN PVOID GuidList,
  31. IN ULONG GuidCount,
  32. IN LPVOID Guid,
  33. OUT PULONG GuidIndex
  34. )
  35. /*++
  36. Routine Description:
  37. This routine will search the list of guids registered and return
  38. the index for the one that was registered.
  39. Arguments:
  40. GuidList is the list of guids to search
  41. GuidCount is the count of guids in the list
  42. Guid is the guid being searched for
  43. *GuidIndex returns the index to the guid
  44. Return Value:
  45. TRUE if guid is found else FALSE
  46. --*/
  47. {
  48. return(FALSE);
  49. }
  50. NTSTATUS
  51. WmlTinySystemControl(
  52. IN OUT PVOID WmiLibInfo,
  53. IN PVOID DeviceObject,
  54. IN PVOID Irp
  55. )
  56. /*++
  57. Routine Description:
  58. Dispatch routine for IRP_MJ_SYSTEM_CONTROL. This routine will process
  59. all wmi requests received, forwarding them if they are not for this
  60. driver or determining if the guid is valid and if so passing it to
  61. the driver specific function for handing wmi requests.
  62. Arguments:
  63. WmiLibInfo has the WMI information control block
  64. DeviceObject - Supplies a pointer to the device object for this request.
  65. Irp - Supplies the Irp making the request.
  66. Return Value:
  67. status
  68. --*/
  69. {
  70. return(STATUS_WMI_GUID_NOT_FOUND);
  71. }
  72. ULONG
  73. WmlTrace(
  74. IN ULONG Type,
  75. IN LPVOID TraceGuid,
  76. IN ULONG64 LoggerHandle,
  77. ... // Pairs: Address, Length
  78. )
  79. {
  80. return STATUS_SUCCESS;
  81. }
  82. ULONG
  83. WmlPrintf(
  84. IN ULONG Type,
  85. IN LPCGUID TraceGuid,
  86. IN ULONG64 LoggerHandle,
  87. IN PCHAR FormatString,
  88. ... // printf var args
  89. )
  90. {
  91. return STATUS_SUCCESS;
  92. }