Source code of Windows XP (NT5)
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.

242 lines
5.6 KiB

  1. /*++
  2. Copyright (c) 1996 Microsoft Corporation
  3. Module Name:
  4. datasrvq.c
  5. Abstract:
  6. a file containing the constant data structures used by the Performance
  7. Monitor data for the Physical Disk Server Queue data objects
  8. Created:
  9. Bob Watson 22-Oct-1996
  10. Revision History:
  11. None.
  12. --*/
  13. //
  14. // Include Files
  15. //
  16. #include <windows.h>
  17. #include <winperf.h>
  18. #include <ntprfctr.h>
  19. #include <perfutil.h>
  20. #include "datasrvq.h"
  21. // dummy variable for field sizing.
  22. static SRVQ_COUNTER_DATA sqcd;
  23. SRVQ_DATA_DEFINITION SrvQDataDefinition = {
  24. {
  25. sizeof(SRVQ_DATA_DEFINITION) + sizeof(SRVQ_COUNTER_DATA),
  26. sizeof(SRVQ_DATA_DEFINITION),
  27. sizeof(PERF_OBJECT_TYPE),
  28. SERVER_QUEUE_OBJECT_TITLE_INDEX,
  29. 0,
  30. 1301,
  31. 0,
  32. PERF_DETAIL_ADVANCED,
  33. (sizeof(SRVQ_DATA_DEFINITION)-sizeof(PERF_OBJECT_TYPE))/
  34. sizeof(PERF_COUNTER_DEFINITION),
  35. 0,
  36. 0,
  37. UNICODE_CODE_PAGE,
  38. {0L,0L},
  39. {0L,0L}
  40. },
  41. { sizeof(PERF_COUNTER_DEFINITION),
  42. 1302,
  43. 0,
  44. 1303,
  45. 0,
  46. 0,
  47. PERF_DETAIL_ADVANCED,
  48. PERF_COUNTER_RAWCOUNT,
  49. sizeof(sqcd.QueueLength),
  50. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->QueueLength
  51. },
  52. { sizeof(PERF_COUNTER_DEFINITION),
  53. 1304,
  54. 0,
  55. 1305,
  56. 0,
  57. 0,
  58. PERF_DETAIL_ADVANCED,
  59. PERF_COUNTER_RAWCOUNT,
  60. sizeof(sqcd.ActiveThreads),
  61. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->ActiveThreads
  62. },
  63. { sizeof(PERF_COUNTER_DEFINITION),
  64. 1306,
  65. 0,
  66. 1307,
  67. 0,
  68. 0,
  69. PERF_DETAIL_ADVANCED,
  70. PERF_COUNTER_RAWCOUNT,
  71. sizeof(sqcd.AvailableThreads),
  72. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->AvailableThreads
  73. },
  74. { sizeof(PERF_COUNTER_DEFINITION),
  75. 1308,
  76. 0,
  77. 1309,
  78. 0,
  79. 0,
  80. PERF_DETAIL_ADVANCED,
  81. PERF_COUNTER_RAWCOUNT,
  82. sizeof(sqcd.AvailableWorkItems),
  83. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->AvailableWorkItems
  84. },
  85. { sizeof(PERF_COUNTER_DEFINITION),
  86. 1310,
  87. 0,
  88. 1311,
  89. 0,
  90. 0,
  91. PERF_DETAIL_ADVANCED,
  92. PERF_COUNTER_RAWCOUNT,
  93. sizeof(sqcd.BorrowedWorkItems),
  94. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->BorrowedWorkItems
  95. },
  96. { sizeof(PERF_COUNTER_DEFINITION),
  97. 1312,
  98. 0,
  99. 1313,
  100. 0,
  101. 0,
  102. PERF_DETAIL_ADVANCED,
  103. PERF_COUNTER_RAWCOUNT,
  104. sizeof(sqcd.WorkItemShortages),
  105. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->WorkItemShortages
  106. },
  107. { sizeof(PERF_COUNTER_DEFINITION),
  108. 1314,
  109. 0,
  110. 1315,
  111. 0,
  112. 0,
  113. PERF_DETAIL_ADVANCED,
  114. PERF_COUNTER_RAWCOUNT,
  115. sizeof(sqcd.CurrentClients),
  116. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->CurrentClients
  117. },
  118. { sizeof(PERF_COUNTER_DEFINITION),
  119. 264,
  120. 0,
  121. 1317,
  122. 0,
  123. -4,
  124. PERF_DETAIL_ADVANCED,
  125. PERF_COUNTER_BULK_COUNT,
  126. sizeof(sqcd.BytesReceived),
  127. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->BytesReceived
  128. },
  129. { sizeof(PERF_COUNTER_DEFINITION),
  130. 506,
  131. 0,
  132. 1319,
  133. 0,
  134. -4,
  135. PERF_DETAIL_ADVANCED,
  136. PERF_COUNTER_BULK_COUNT,
  137. sizeof(sqcd.BytesSent),
  138. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->BytesSent
  139. },
  140. { sizeof(PERF_COUNTER_DEFINITION),
  141. 1320,
  142. 0,
  143. 1321,
  144. 0,
  145. -4,
  146. PERF_DETAIL_ADVANCED,
  147. PERF_COUNTER_BULK_COUNT,
  148. sizeof(sqcd.TotalBytesTransfered),
  149. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->TotalBytesTransfered
  150. },
  151. { sizeof(PERF_COUNTER_DEFINITION),
  152. 288,
  153. 0,
  154. 1323,
  155. 0,
  156. 0,
  157. PERF_DETAIL_ADVANCED,
  158. PERF_COUNTER_BULK_COUNT,
  159. sizeof(sqcd.ReadOperations),
  160. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->ReadOperations
  161. },
  162. { sizeof(PERF_COUNTER_DEFINITION),
  163. 1324,
  164. 0,
  165. 1325,
  166. 0,
  167. -4,
  168. PERF_DETAIL_ADVANCED,
  169. PERF_COUNTER_BULK_COUNT,
  170. sizeof(sqcd.BytesRead),
  171. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->BytesRead
  172. },
  173. { sizeof(PERF_COUNTER_DEFINITION),
  174. 298,
  175. 0,
  176. 1327,
  177. 0,
  178. 0,
  179. PERF_DETAIL_ADVANCED,
  180. PERF_COUNTER_BULK_COUNT,
  181. sizeof(sqcd.WriteOperations),
  182. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->WriteOperations
  183. },
  184. { sizeof(PERF_COUNTER_DEFINITION),
  185. 1328,
  186. 0,
  187. 1329,
  188. 0,
  189. -4,
  190. PERF_DETAIL_ADVANCED,
  191. PERF_COUNTER_BULK_COUNT,
  192. sizeof(sqcd.BytesWritten),
  193. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->BytesWritten
  194. },
  195. { sizeof(PERF_COUNTER_DEFINITION),
  196. 508,
  197. 0,
  198. 1331,
  199. 0,
  200. -4,
  201. PERF_DETAIL_ADVANCED,
  202. PERF_COUNTER_BULK_COUNT,
  203. sizeof(sqcd.TotalBytes),
  204. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->TotalBytes
  205. },
  206. { sizeof(PERF_COUNTER_DEFINITION),
  207. 1332,
  208. 0,
  209. 1333,
  210. 0,
  211. 0,
  212. PERF_DETAIL_ADVANCED,
  213. PERF_COUNTER_BULK_COUNT,
  214. sizeof(sqcd.TotalOperations),
  215. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->TotalOperations
  216. },
  217. { sizeof(PERF_COUNTER_DEFINITION),
  218. 404,
  219. 0,
  220. 405,
  221. 0,
  222. 0,
  223. PERF_DETAIL_ADVANCED,
  224. PERF_COUNTER_COUNTER,
  225. sizeof(sqcd.TotalContextBlocksQueued),
  226. (DWORD)(ULONG_PTR)&((SRVQ_COUNTER_DATA *)0)->TotalContextBlocksQueued
  227. }
  228. };
  229.