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.

250 lines
3.4 KiB

  1. // wmi.h
  2. #define SERIAL_WMI_PARITY_NONE 0U
  3. #define SERIAL_WMI_PARITY_ODD 1U
  4. #define SERIAL_WMI_PARITY_EVEN 2U
  5. #define SERIAL_WMI_PARITY_SPACE 3U
  6. #define SERIAL_WMI_PARITY_MARK 4U
  7. #define SERIAL_WMI_STOP_1 0U
  8. #define SERIAL_WMI_STOP_1_5 1U
  9. #define SERIAL_WMI_STOP_2 2U
  10. #define SERIAL_WMI_INTTYPE_LATCHED 0U
  11. #define SERIAL_WMI_INTTYPE_LEVEL 1U
  12. typedef struct _SERIAL_WMI_COMM_DATA {
  13. //
  14. // Name -- inside struct
  15. //
  16. //
  17. // Baud rate
  18. //
  19. UINT32 BaudRate;
  20. //
  21. // BitsPerByte;
  22. //
  23. UINT32 BitsPerByte;
  24. //
  25. // Parity -- see SERIAL_WMI_PARITY_XXXX
  26. //
  27. UINT32 Parity;
  28. //
  29. // Parity Enabled
  30. //
  31. BOOLEAN ParityCheckEnable;
  32. //
  33. // Stop Bits - see SERIAL_WMI_STOP_XXXX
  34. //
  35. UINT32 StopBits;
  36. //
  37. // XOff Character
  38. //
  39. UINT32 XoffCharacter;
  40. //
  41. // Xoff Xmit Threshold
  42. //
  43. UINT32 XoffXmitThreshold;
  44. //
  45. // XOn Character
  46. //
  47. UINT32 XonCharacter;
  48. //
  49. // XonXmit Threshold
  50. //
  51. UINT32 XonXmitThreshold;
  52. //
  53. // Maximum Baud Rate
  54. //
  55. UINT32 MaximumBaudRate;
  56. //
  57. // Maximum Output Buffer Size
  58. //
  59. UINT32 MaximumOutputBufferSize;
  60. //
  61. // Support 16-bit mode (NOT!)
  62. //
  63. BOOLEAN Support16BitMode;
  64. //
  65. // Support DTRDSR
  66. //
  67. BOOLEAN SupportDTRDSR;
  68. //
  69. // Support Interval Timeouts
  70. //
  71. BOOLEAN SupportIntervalTimeouts;
  72. //
  73. // Support parity check
  74. //
  75. BOOLEAN SupportParityCheck;
  76. //
  77. // Support RTS CTS
  78. //
  79. BOOLEAN SupportRTSCTS;
  80. //
  81. // Support XOnXOff
  82. //
  83. BOOLEAN SupportXonXoff;
  84. //
  85. // Support Settable Baud Rate
  86. //
  87. BOOLEAN SettableBaudRate;
  88. //
  89. // Settable Data Bits
  90. //
  91. BOOLEAN SettableDataBits;
  92. //
  93. // Settable Flow Control
  94. //
  95. BOOLEAN SettableFlowControl;
  96. //
  97. // Settable Parity
  98. //
  99. BOOLEAN SettableParity;
  100. //
  101. // Settable Parity Check
  102. //
  103. BOOLEAN SettableParityCheck;
  104. //
  105. // Settable Stop Bits
  106. //
  107. BOOLEAN SettableStopBits;
  108. //
  109. // Is Busy
  110. //
  111. BOOLEAN IsBusy;
  112. } SERIAL_WMI_COMM_DATA, *PSERIAL_WMI_COMM_DATA;
  113. typedef struct _SERIAL_WMI_HW_DATA {
  114. //
  115. // IRQ Number
  116. //
  117. UINT32 IrqNumber;
  118. //
  119. // IRQ Vector;
  120. //
  121. UINT32 IrqVector;
  122. //
  123. // IRQ Level
  124. //
  125. UINT32 IrqLevel;
  126. //
  127. // IRQ Affinity Mask
  128. //
  129. UINT32 IrqAffinityMask;
  130. //
  131. // Interrupt Type
  132. //
  133. UINT32 InterruptType;
  134. //
  135. // Base IO Addr
  136. //
  137. ULONG_PTR BaseIOAddress;
  138. } SERIAL_WMI_HW_DATA, *PSERIAL_WMI_HW_DATA;
  139. typedef struct _SERIAL_WMI_PERF_DATA {
  140. //
  141. // Bytes received in current session
  142. //
  143. UINT32 ReceivedCount;
  144. //
  145. // Bytes transmitted in current session
  146. //
  147. UINT32 TransmittedCount;
  148. //
  149. // Framing errors in current session
  150. //
  151. UINT32 FrameErrorCount;
  152. //
  153. // Serial overrun errors in current session
  154. //
  155. UINT32 SerialOverrunErrorCount;
  156. //
  157. // Buffer overrun errors in current session
  158. //
  159. UINT32 BufferOverrunErrorCount;
  160. //
  161. // Parity errors in current session
  162. //
  163. UINT32 ParityErrorCount;
  164. } SERIAL_WMI_PERF_DATA, *PSERIAL_WMI_PERF_DATA;
  165. #define SERIAL_WMI_GUID_LIST_SIZE 4
  166. extern WMIGUIDREGINFO SerialWmiGuidList[SERIAL_WMI_GUID_LIST_SIZE];