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.

113 lines
2.7 KiB

  1. /*++
  2. Copyright (c) 1995 Microsoft Corporation
  3. Module Name:
  4. acddefs.h
  5. Abstract:
  6. Shared internal structure defintions for the Implicit
  7. Connection Driver (acd.sys).
  8. Author:
  9. Anthony Discolo (adiscolo) 23-Jun-1995
  10. Environment:
  11. Kernel Mode
  12. Revision History:
  13. --*/
  14. #ifndef _ACDDEFS_
  15. #define _ACDDEFS_
  16. //
  17. // Min macro
  18. //
  19. #define MIN(a, b) (a) < (b) ? (a) : (b)
  20. //
  21. // List entry structure for the AcdCompletionQueue.
  22. //
  23. typedef struct _ACD_COMPLETION {
  24. LIST_ENTRY ListEntry;
  25. ULONG ulDriverId; // transport driver id
  26. BOOLEAN fCanceled; // TRUE if request was canceled
  27. BOOLEAN fCompleted; // TRUE if request was completed
  28. ACD_NOTIFICATION notif;
  29. ACD_CONNECT_CALLBACK pProc; // callback proc
  30. USHORT nArgs; // argument count
  31. PVOID pArgs[1]; // variable length arguments
  32. } ACD_COMPLETION, *PACD_COMPLETION;
  33. //
  34. // A connection block.
  35. //
  36. // For each pending connection, there is a
  37. // connection block that describes the current
  38. // state.
  39. //
  40. typedef struct _ACD_CONNECTION {
  41. LIST_ENTRY ListEntry; // connection list
  42. BOOLEAN fNotif; // TRUE if service has been notified
  43. BOOLEAN fProgressPing; // TRUE if service has pinged
  44. BOOLEAN fCompleting; // TRUE if in AcdSignalCompletionCommon
  45. ULONG ulTimerCalls; // # of total pings
  46. ULONG ulMissedPings; // # of missed pings
  47. LIST_ENTRY CompletionList; // completion list
  48. } ACD_CONNECTION, *PACD_CONNECTION;
  49. typedef struct _ACD_DISABLED_ADDRESSES {
  50. LIST_ENTRY ListEntry;
  51. ULONG ulNumAddresses;
  52. ULONG ulMaxAddresses;
  53. } ACD_DISABLED_ADDRESSES, *PACD_DISABLED_ADDRESSES;
  54. typedef struct _ACD_DISABLED_ADDRESS {
  55. LIST_ENTRY ListEntry;
  56. ACD_ENABLE_ADDRESS EnableAddress;
  57. } ACD_DISABLED_ADDRESS, *PACD_DISABLED_ADDRESS;
  58. //
  59. // Generic hash table entry.
  60. //
  61. typedef struct _HASH_ENTRY {
  62. LIST_ENTRY ListEntry;
  63. ACD_ADDR szKey;
  64. ULONG ulData;
  65. } HASH_ENTRY, *PHASH_ENTRY;
  66. extern KSPIN_LOCK AcdSpinLockG;
  67. extern KEVENT AcdRequestThreadEventG;
  68. extern LIST_ENTRY AcdNotificationQueueG;
  69. extern LIST_ENTRY AcdCompletionQueueG;
  70. extern LIST_ENTRY AcdConnectionQueueG;
  71. extern LIST_ENTRY AcdDriverListG;
  72. extern BOOLEAN fConnectionInProgressG;
  73. extern BOOLEAN fProgressPingG;
  74. extern ULONG nTimerCallsG;
  75. extern ULONG nMissedPingsG;
  76. extern PDEVICE_OBJECT pAcdDeviceObjectG;
  77. extern ACD_ADDR szComputerName;
  78. extern BOOLEAN AcdStopThread;
  79. //
  80. // Miscellaneous routines.
  81. //
  82. VOID
  83. AcdPrintAddress(
  84. IN PACD_ADDR pAddr
  85. );
  86. #endif // _ACDDEFS_