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.

614 lines
9.1 KiB

  1. /*++ BUILD Version: 0001 // Increment this if a change has global effects
  2. Copyright (c) 1992 Microsoft Corporation
  3. Module Name:
  4. datasfm.c
  5. Abstract:
  6. a file containing the constant data structures used by the Performance
  7. Monitor data for the MacFile extensible counters.
  8. This file contains a set of constant data structures which are
  9. currently defined for the MacFile extensible counters.
  10. Created:
  11. Russ Blake 26 Feb 93
  12. Sue Adams 03 Jun 93 - Adapt for use by MacFile counters
  13. Revision History:
  14. Sue Adams 23 Feb 94 - Hard code counter and help indexes since these
  15. values are now part of the NT base system counter
  16. index values.
  17. --*/
  18. //
  19. // Include Files
  20. //
  21. #include <windows.h>
  22. #include <winperf.h>
  23. #include "datasfm.h"
  24. //
  25. // Constant structure initializations
  26. // defined in datasfm.h
  27. //
  28. SFM_DATA_DEFINITION SfmDataDefinition = {
  29. {
  30. // TotalByteLength
  31. sizeof(SFM_DATA_DEFINITION) + SIZE_OF_SFM_PERFORMANCE_DATA,
  32. // DefinitionLength
  33. sizeof(SFM_DATA_DEFINITION),
  34. // HeaderLength
  35. sizeof(PERF_OBJECT_TYPE),
  36. // ObjectNameTitleIndex
  37. 1000,
  38. // ObjectNameTitle
  39. 0,
  40. // ObjectHelpTitleIndex
  41. 1001,
  42. // ObjectHelpTitle
  43. 0,
  44. // DetailLevel
  45. PERF_DETAIL_NOVICE,
  46. // NumCounters
  47. (sizeof(SFM_DATA_DEFINITION)-sizeof(PERF_OBJECT_TYPE)) / sizeof(PERF_COUNTER_DEFINITION),
  48. // DefaultCounter
  49. 0,
  50. // NumInstances
  51. PERF_NO_INSTANCES,
  52. // CodePage
  53. 0,
  54. // PerfTime
  55. {0,0},
  56. // PerfFreq
  57. {0,0}
  58. },
  59. {
  60. // ByteLength
  61. sizeof(PERF_COUNTER_DEFINITION),
  62. // CounterNameTitleIndex
  63. 1002,
  64. // CounterNameTitle
  65. 0,
  66. // CounterHelpTitleIndex
  67. 1003,
  68. // CounterHelpTitle
  69. 0,
  70. // DefaultScale
  71. -4,
  72. // DetailLevel
  73. PERF_DETAIL_NOVICE,
  74. // CounterType
  75. PERF_COUNTER_RAWCOUNT,
  76. // CounterSize
  77. sizeof(DWORD),
  78. // CounterOffset
  79. NUM_MAXPAGD_OFFSET
  80. },
  81. {
  82. // ByteLength
  83. sizeof(PERF_COUNTER_DEFINITION),
  84. // CounterNameTitleIndex
  85. 1004,
  86. // CounterNameTitle
  87. 0,
  88. // CounterHelpTitleIndex
  89. 1005,
  90. // CounterHelpTitle
  91. 0,
  92. // DefaultScale
  93. -4,
  94. // DetailLevel
  95. PERF_DETAIL_NOVICE,
  96. // CounterType
  97. PERF_COUNTER_RAWCOUNT,
  98. // CounterSize
  99. sizeof(DWORD),
  100. // CounterOffset
  101. NUM_CURPAGD_OFFSET
  102. },
  103. {
  104. // ByteLength
  105. sizeof(PERF_COUNTER_DEFINITION),
  106. // CounterNameTitleIndex
  107. 1006,
  108. // CounterNameTitle
  109. 0,
  110. // CounterHelpTitleIndex
  111. 1007,
  112. // CounterHelpTitle
  113. 0,
  114. // DefaultScale
  115. -4,
  116. // DetailLevel
  117. PERF_DETAIL_NOVICE,
  118. // CounterType
  119. PERF_COUNTER_RAWCOUNT,
  120. // CounterSize
  121. sizeof(DWORD),
  122. // CounterOffset
  123. NUM_MAXNONPAGD_OFFSET
  124. },
  125. {
  126. // ByteLength
  127. sizeof(PERF_COUNTER_DEFINITION),
  128. // CounterNameTitleIndex
  129. 1008,
  130. // CounterNameTitle
  131. 0,
  132. // CounterHelpTitleIndex
  133. 1009,
  134. // CounterHelpTitle
  135. 0,
  136. // DefaultScale
  137. -4,
  138. // DetailLevel
  139. PERF_DETAIL_NOVICE,
  140. // CounterType
  141. PERF_COUNTER_RAWCOUNT,
  142. // CounterSize
  143. sizeof(DWORD),
  144. // CounterOffset
  145. NUM_CURNONPAGD_OFFSET
  146. },
  147. {
  148. // ByteLength
  149. sizeof(PERF_COUNTER_DEFINITION),
  150. // CounterNameTitleIndex
  151. 1010,
  152. // CounterNameTitle
  153. 0,
  154. // CounterHelpTitleIndex
  155. 1011,
  156. // CounterHelpTitle
  157. 0,
  158. // DefaultScale
  159. 0,
  160. // DetailLevel
  161. PERF_DETAIL_NOVICE,
  162. // CounterType
  163. PERF_COUNTER_RAWCOUNT,
  164. // CounterSize
  165. sizeof(DWORD),
  166. // CounterOffset
  167. NUM_CURSESSIONS_OFFSET
  168. },
  169. {
  170. // ByteLength
  171. sizeof(PERF_COUNTER_DEFINITION),
  172. // CounterNameTitleIndex
  173. 1012,
  174. // CounterNameTitle
  175. 0,
  176. // CounterHelpTitleIndex
  177. 1013,
  178. // CounterHelpTitle
  179. 0,
  180. // DefaultScale
  181. 0,
  182. // DetailLevel
  183. PERF_DETAIL_NOVICE,
  184. // CounterType
  185. PERF_COUNTER_RAWCOUNT,
  186. // CounterSize
  187. sizeof(DWORD),
  188. // CounterOffset
  189. NUM_MAXSESSIONS_OFFSET
  190. },
  191. {
  192. // ByteLength
  193. sizeof(PERF_COUNTER_DEFINITION),
  194. // CounterNameTitleIndex
  195. 1014,
  196. // CounterNameTitle
  197. 0,
  198. // CounterHelpTitleIndex
  199. 1015,
  200. // CounterHelpTitle
  201. 0,
  202. // DefaultScale
  203. 0,
  204. // DetailLevel
  205. PERF_DETAIL_WIZARD,
  206. // CounterType
  207. PERF_COUNTER_RAWCOUNT,
  208. // CounterSize
  209. sizeof(DWORD),
  210. // CounterOffset
  211. NUM_CURFILESOPEN_OFFSET
  212. },
  213. {
  214. // ByteLength
  215. sizeof(PERF_COUNTER_DEFINITION),
  216. // CounterNameTitleIndex
  217. 1016,
  218. // CounterNameTitle
  219. 0,
  220. // CounterHelpTitleIndex
  221. 1017,
  222. // CounterHelpTitle
  223. 0,
  224. // DefaultScale
  225. 0,
  226. // DetailLevel
  227. PERF_DETAIL_WIZARD,
  228. // CounterType
  229. PERF_COUNTER_RAWCOUNT,
  230. // CounterSize
  231. sizeof(DWORD),
  232. // CounterOffset
  233. NUM_MAXFILESOPEN_OFFSET
  234. },
  235. {
  236. // ByteLength
  237. sizeof(PERF_COUNTER_DEFINITION),
  238. // CounterNameTitleIndex
  239. 1018,
  240. // CounterNameTitle
  241. 0,
  242. // CounterHelpTitleIndex
  243. 1019,
  244. // CounterHelpTitle
  245. 0,
  246. // DefaultScale
  247. 0,
  248. // DetailLevel
  249. PERF_DETAIL_NOVICE,
  250. // CounterType
  251. PERF_COUNTER_RAWCOUNT,
  252. // CounterSize
  253. sizeof(DWORD),
  254. // CounterOffset
  255. NUM_NUMFAILEDLOGINS_OFFSET
  256. },
  257. {
  258. // ByteLength
  259. sizeof(PERF_COUNTER_DEFINITION),
  260. // CounterNameTitleIndex
  261. 1020,
  262. // CounterNameTitle
  263. 0,
  264. // CounterHelpTitleIndex
  265. 1021,
  266. // CounterHelpTitle
  267. 0,
  268. // DefaultScale
  269. -4,
  270. // DetailLevel
  271. PERF_DETAIL_NOVICE,
  272. // CounterType
  273. PERF_COUNTER_BULK_COUNT,
  274. // CounterSize
  275. sizeof(LARGE_INTEGER),
  276. // CounterOffset
  277. NUM_DATAREAD_OFFSET
  278. },
  279. {
  280. // ByteLength
  281. sizeof(PERF_COUNTER_DEFINITION),
  282. // CounterNameTitleIndex
  283. 1022,
  284. // CounterNameTitle
  285. 0,
  286. // CounterHelpTitleIndex
  287. 1023,
  288. // CounterHelpTitle
  289. 0,
  290. // DefaultScale
  291. -4,
  292. // DetailLevel
  293. PERF_DETAIL_NOVICE,
  294. // CounterType
  295. PERF_COUNTER_BULK_COUNT,
  296. // CounterSize
  297. sizeof(LARGE_INTEGER),
  298. // CounterOffset
  299. NUM_DATAWRITTEN_OFFSET
  300. },
  301. {
  302. // ByteLength
  303. sizeof(PERF_COUNTER_DEFINITION),
  304. // CounterNameTitleIndex
  305. 1024,
  306. // CounterNameTitle
  307. 0,
  308. // CounterHelpTitleIndex
  309. 1025,
  310. // CounterHelpTitle
  311. 0,
  312. // DefaultScale
  313. -4,
  314. // DetailLevel
  315. PERF_DETAIL_NOVICE,
  316. // CounterType
  317. PERF_COUNTER_BULK_COUNT,
  318. // CounterSize
  319. sizeof(LARGE_INTEGER),
  320. // CounterOffset
  321. NUM_DATAIN_OFFSET
  322. },
  323. {
  324. // ByteLength
  325. sizeof(PERF_COUNTER_DEFINITION),
  326. // CounterNameTitleIndex
  327. 1026,
  328. // CounterNameTitle
  329. 0,
  330. // CounterHelpTitleIndex
  331. 1027,
  332. // CounterHelpTitle
  333. 0,
  334. // DefaultScale
  335. -4,
  336. // DetailLevel
  337. PERF_DETAIL_NOVICE,
  338. // CounterType
  339. PERF_COUNTER_BULK_COUNT,
  340. // CounterSize
  341. sizeof(LARGE_INTEGER),
  342. // CounterOffset
  343. NUM_DATAOUT_OFFSET
  344. },
  345. {
  346. // ByteLength
  347. sizeof(PERF_COUNTER_DEFINITION),
  348. // CounterNameTitleIndex
  349. 1028,
  350. // CounterNameTitle
  351. 0,
  352. // CounterHelpTitleIndex
  353. 1029,
  354. // CounterHelpTitle
  355. 0,
  356. // DefaultScale
  357. 0,
  358. // DetailLevel
  359. PERF_DETAIL_NOVICE,
  360. // CounterType
  361. PERF_COUNTER_RAWCOUNT,
  362. // CounterSize
  363. sizeof(DWORD),
  364. // CounterOffset
  365. NUM_CURQUEUELEN_OFFSET
  366. },
  367. {
  368. // ByteLength
  369. sizeof(PERF_COUNTER_DEFINITION),
  370. // CounterNameTitleIndex
  371. 1030,
  372. // CounterNameTitle
  373. 0,
  374. // CounterHelpTitleIndex
  375. 1031,
  376. // CounterHelpTitle
  377. 0,
  378. // DefaultScale
  379. 0,
  380. // DetailLevel
  381. PERF_DETAIL_NOVICE,
  382. // CounterType
  383. PERF_COUNTER_RAWCOUNT,
  384. // CounterSize
  385. sizeof(DWORD),
  386. // CounterOffset
  387. NUM_MAXQUEUELEN_OFFSET
  388. },
  389. {
  390. // ByteLength
  391. sizeof(PERF_COUNTER_DEFINITION),
  392. // CounterNameTitleIndex
  393. 1032,
  394. // CounterNameTitle
  395. 0,
  396. // CounterHelpTitleIndex
  397. 1033,
  398. // CounterHelpTitle
  399. 0,
  400. // DefaultScale
  401. 0,
  402. // DetailLevel
  403. PERF_DETAIL_NOVICE,
  404. // CounterType
  405. PERF_COUNTER_RAWCOUNT,
  406. // CounterSize
  407. sizeof(DWORD),
  408. // CounterOffset
  409. NUM_CURTHREADS_OFFSET
  410. },
  411. {
  412. // ByteLength
  413. sizeof(PERF_COUNTER_DEFINITION),
  414. // CounterNameTitleIndex
  415. 1034,
  416. // CounterNameTitle
  417. 0,
  418. // CounterHelpTitleIndex
  419. 1035,
  420. // CounterHelpTitle
  421. 0,
  422. // DefaultScale
  423. 0,
  424. // DetailLevel
  425. PERF_DETAIL_NOVICE,
  426. // CounterType
  427. PERF_COUNTER_RAWCOUNT,
  428. // CounterSize
  429. sizeof(DWORD),
  430. // CounterOffset
  431. NUM_MAXTHREADS_OFFSET
  432. }
  433. };
  434.