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.

87 lines
2.2 KiB

  1. #pragma once
  2. #include "intflist.h"
  3. extern HINSTANCE g_hInstance;
  4. extern UINT g_nThreads;
  5. VOID WINAPI
  6. WZCSvcMain(
  7. IN DWORD dwArgc,
  8. IN LPTSTR *lpszArgv);
  9. DWORD
  10. WZCSvcWMINotification(
  11. IN BOOL bRegister);
  12. DWORD
  13. WZCSvcUpdateStatus();
  14. DWORD
  15. WZCSvcControlHandler(
  16. IN DWORD dwControl,
  17. IN DWORD dwEventType,
  18. IN PVOID pEventData,
  19. IN PVOID pContext);
  20. VOID CALLBACK
  21. WZCSvcWMINotificationHandler(
  22. IN PWNODE_HEADER pWnodeHdr,
  23. IN UINT_PTR uiNotificationContext);
  24. // all the device notifications are forwarded from the specific
  25. // handler to the central handler below.
  26. VOID
  27. WZCWrkDeviceNotifHandler(
  28. IN LPVOID pvData);
  29. // WZCTimeoutCallback: timer callback routine. It should not lock any cs, but just spawn
  30. // the timer handler routine after referencing the context (to avoid premature deletion)
  31. VOID WINAPI
  32. WZCTimeoutCallback(
  33. IN PVOID pvData,
  34. IN BOOL fTimerOrWaitFired);
  35. VOID
  36. WZCSvcTimeoutHandler(
  37. IN PVOID pvData);
  38. VOID
  39. WZCWrkWzcSendNotif(
  40. IN LPVOID pvData);
  41. VOID
  42. WZCSvcShutdown(IN DWORD dwErrorCode);
  43. // Internal WZC service settings.
  44. typedef struct _WZC_INTERNAL_CONTEXT
  45. {
  46. BOOL bValid; // indicates whether the context is valid (cs is initialized)
  47. WZC_CONTEXT wzcContext; // global WZC settings (timers, flags, etc)
  48. PINTF_CONTEXT pIntfTemplate; // global interface context template.
  49. CRITICAL_SECTION csContext;
  50. } WZC_INTERNAL_CONTEXT, *PWZC_INTERNAL_CONTEXT;
  51. // WZCContextInit, WZCContextDestroy
  52. // Description: Initialise and Destroy a context
  53. // Parameters:
  54. // [in] pwzcICtxt, pointer to a valid internal context object
  55. // Returns: Win32 error code
  56. DWORD WZCContextInit(
  57. IN PWZC_INTERNAL_CONTEXT pwzcICtxt);
  58. DWORD WZCContextDestroy(
  59. IN PWZC_INTERNAL_CONTEXT pwzcICtxt);
  60. // WzcContextQuery, WzcContextSet
  61. // Description: Query and set the context
  62. // Returns: win32 error code
  63. DWORD WzcContextQuery(
  64. DWORD dwInFlags,
  65. PWZC_CONTEXT pContext,
  66. LPDWORD pdwOutFlags);
  67. DWORD WzcContextSet(
  68. DWORD dwInFlags,
  69. PWZC_CONTEXT pContext,
  70. LPDWORD pdwOutFlags);
  71. extern WZC_INTERNAL_CONTEXT g_wzcInternalCtxt;