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.

340 lines
12 KiB

  1. //******************************************
  2. // System Trace Definitions
  3. // Version 0004.0 18th December 2003
  4. //******************************************
  5. // The #typev statement and the #typev statement may be used to convert
  6. // messages into user readable forms.
  7. // With #typev all parameters are processed as strings and the default string
  8. // processing of FormTMessage is used
  9. // With #typev wherever possible parameters are processed as their native format
  10. // and the %x!x! style of FormatMessage should be used.
  11. //
  12. // Note Parameter %1 through %9 are predefined
  13. // Parameter is #typev
  14. // %1 GUID Friendly Name string
  15. // %2 GUID SubType Name string
  16. // %3 Thread ID ULONG_PTR
  17. // %4 System Time String
  18. // %5 Kernel Time or User Time String
  19. // %6 User Time or NULL String
  20. // %7 Sequence Number LONG
  21. // %8 Unused String
  22. // %9 CPU Number LONG
  23. // %10 and above are the user parameters
  24. // %255 Is reserved
  25. //
  26. // Note these parameters are always present, but may not be valid
  27. // depending on the source.
  28. //
  29. // User defined messages always start at message number 10
  30. // Messages 0 through 9 are reserved for system use.
  31. // Message number 255 is reserved.
  32. //
  33. // Available formats for user arguments are -
  34. //
  35. //Name Description #typev Format
  36. //ItemChar CHAR
  37. //ItemUChar UCHAR
  38. //ItemCharShort USHORT
  39. //ItemCharSign SHORT
  40. //ItemShort Signed Short SHORT
  41. //ItemUShort Unsigned Short USHORT
  42. //ItemLong Signed Long, decoded as decimal LONG
  43. //ItemULong Unsigned Long, decoded as decimal ULONG
  44. //ItemULongX Unsigned Long, seen as hexadecimal ULONG
  45. //ItemLongLong Signed 64 Bit value LONGLONG
  46. //ItemULongLong Unsigned 64 Bit value ULONGLONG
  47. //ItemRString Reduced Ascii String String
  48. // (\t, \n, \r, \,, converted to space, trailing sp removed)
  49. //ItemWString Unicode String, null terminated String
  50. //ItemPString Counted Ascii String String
  51. //ItemPWString Counted Unicode String String
  52. //ItemMLString Multi-Line Ascii String String
  53. //ItemSid Security identifier String
  54. //ItemChar4 CHAR4
  55. //ItemIPAddr IP Address String (If needed raw, use ItemUlong)
  56. // (string of form xxx.xxx.xxx.xxx)
  57. //ItemPort String (If needed raw use ItemUshort)
  58. //ItemNWString Non-null terminated Wide Char String String
  59. //ItemListByte (element1,element2,....) String
  60. // byte index into a list of strings
  61. //ItemListShort(element1,element2,....) String
  62. // short index into a list of strings
  63. //ItemListLong (element1,element2,....) String
  64. // Long index into a list of strings
  65. //ItemGUID Normal GUID format String
  66. //ItemNTerror Translates a ULONG error code to the String
  67. // NT Error Text
  68. //ItemNTSTATUS Converts NTSTATUS to symbolic name String
  69. //ItemWINERROR Converts WINERROR to symbolic name String
  70. //ItemNETEVENT Converts NETEVENT to symbolic name String
  71. //ItemMerror module.ext String
  72. // Translates a ULONG error code using the
  73. // module specified.
  74. //ItemTimeStamp Treats a LONGLONG as a timestamp String
  75. //ItemUnknown String
  76. ce5b1020-8ea9-11d0-a4ec-00a0c9062910 TraceDp
  77. #typev Start 1 "TraceDp TID=0x%3 Start"
  78. #typev End 2 "TraceDp TID=0x%3End"
  79. {
  80. }
  81. 68fdd900-4a3e-11d1-84f4-0000f80464e3 EventTrace
  82. #typev Header 0 "%0EventTrace Header"
  83. {
  84. }
  85. 2cb15d1d-5fc1-11d2-abe1-00a0c911f518 Image
  86. #typev Load 10 "%0ImageLoad of %13!s! (Process= %12!d!, Base=0x%10!X!,size=0x%11!X!)"
  87. {
  88. Base Address, ItemPtr
  89. Module Size, ItemPtr
  90. ProcessId, ItemUlong
  91. Image Filename, ItemWString
  92. }
  93. 3d6fa8d0-fe05-11d0-9dda-00c04fd7ba7c Process
  94. #typev Start 1 "%0Started Process %11!04X!.%12!04X! %16!s! :: %15!s! (Session=%13!d!) "
  95. #typev End 2 "%0Ended Process %11!04X!.%12!04X! %16!s! :: %15!s! (Session=%13!d!) Exit Status %14!X!"
  96. #typev DCStart 3 "%0Data Collection Started of %11!04X!.%12!04X! %16!s! :: %15!s! (Session=%13!d!)"
  97. #typev DCEnd 4 "%0Data Colection Ended for %11!04X!.%12!04X! %16!s! :: %15!s! (Session=%13!d!)"
  98. #typev Load 5 "%0Load of %11!04X!.%12!04X! %16!s! :: %15!s! (Session=%13!d!)"
  99. {
  100. PageDirectoryBase, ItemPtr
  101. Process Id, ItemULong
  102. Parent Id, ItemULong
  103. Session Id, ItemULong
  104. Exit Status, ItemUlong
  105. User SID, ItemSid
  106. Image FileName, ItemString
  107. }
  108. 3d6fa8d1-fe05-11d0-9dda-00c04fd7ba7c Thread
  109. #typev Start 1 "%0Started Thread %10!04X!.%11!04X!"
  110. #typev DCStart 3 "%0Data Collection Started for %10!04X!.%11!04X!"
  111. {
  112. Process Id, ItemULong
  113. Thread Id, ItemULong
  114. StackBase, ItemPtr
  115. StackLimit, ItemPtr
  116. UserStackBase, ItemPtr
  117. UserStackLimit, ItemPtr
  118. StartAddr, ItemPtr
  119. Win32StartAddr, ItemPtr
  120. WaitMode, ItemChar
  121. }
  122. #typev End 2 "%0Ended Thread %10!04X!.%11!04X!"
  123. #typev DCEnd 4 "%0Data Collection Ended for %10!04X!.%11!04X!"
  124. {
  125. Process Id, ItemULong
  126. Thread Id, ItemULong
  127. }
  128. 3d6fa8d3-fe05-11d0-9dda-00c04fd7ba7c PageFault
  129. #typev TransitionFault 10 "%0Pagefault Transition VA=0x%10!08X!, PC=0x%11!08X!"
  130. #typev DemandZeroFault 11 "%0Pagefault DemandZero VA=0x%10!08X!, PC=0x%11!08X!"
  131. #typev CopyOnWrite 12 "%0Pagefault CopyOnWrite VA=0x%10!08X!, PC=0x%11!08X!"
  132. #typev GlobalPageFault 13 "%0Pagefault GuardPageFault VA=0x%10!08X!, PC=0x%11!08X!"
  133. #typev Hard 14 "%0Pagefault Hard VA=0x%10!08X!, PC=0x%11!08X!, in %12!016X!"
  134. #typev Notification 15 "%0Pagefault Notification VA=0x%10!08X!, PC=0x%11!08X!, in %12!016X!"
  135. {
  136. Virtual Address,ItemULongX
  137. Program Counter,ItemUlongX
  138. Byte Offset, ItemLongLong
  139. File Object, ItemUlongX
  140. Byte Count, ItemUlong
  141. HotFile Name, ItemNWString
  142. }
  143. 01853a65-418f-4f36-aefc-dc0f1d2fd235 Config
  144. #typev CPU 10 "%0%15!s!(%16!s!) :: CPU # %11!d!, Speed %10!d!Mhz, Memory %12!d!K, PageSize %13!d!K, AllocationGranularity %14!d!"
  145. {
  146. MHz, ItemULong //10
  147. NumberOfProcessors, ItemULong //11
  148. MemSize, ItemULong //12
  149. PageSize, ItemULong //13
  150. AllocationGranularity, ItemULong //14
  151. ComputerName, ItemWChar[256] //15
  152. DomainName, ItemWChar[132] //16
  153. }
  154. #typev PhyDisk 11 "%0Phsical Disk %10!d!(%19!s!), SectorSize: %11!d!, SectorsperTrack: %12!d!, TracksPerCylinder %13!d! Cylinders %14!d!, SCSI (Port=%15!d!, Path %16!d!, Target=%17!d!, Lun=%18!d!)"
  155. {
  156. DiskNumber, ItemULong //10
  157. BytesPerSector, ItemULong //11
  158. SectorsPerTrack, ItemULong //12
  159. TracksPerCylinder, ItemULong //13
  160. Cylinders, ItemULongLong //14
  161. SCSIPort, ItemULong //15
  162. SCSIPath, ItemULong //16
  163. SCSITarget, ItemULong //17
  164. SCSILun, ItemULong //18
  165. Manufacturer, ItemWChar[256] //19
  166. PartitionCount, ItemULong //20
  167. WriteCacheEnabled, ItemBool //21
  168. BootDriveLetter, ItemWChar[3] //22
  169. }
  170. #typev LogDisk 12 "%0Logical Disk %12!d! %15!s! "
  171. {
  172. StartOffset, ItemULongLong //10
  173. PartitionSize, ItemULongLong //11
  174. DiskNumber, ItemULong //12
  175. Size, ItemULong //13
  176. DriveType, ItemULong //14
  177. DriveLetterString, ItemWChar[4] //15
  178. Pad, ItemULong //16
  179. PartitionNumber, ItemULong //17
  180. SectorsPerCluster, ItemULong //18
  181. BytesPerSector, ItemULong //19
  182. NumberOfFreeClusters, ItemLongLong //20
  183. TotalNumberOfClusters, ItemLongLong //21
  184. FileSystem, ItemWChar[16] //22
  185. VolumeExt, ItemULong
  186. }
  187. #typev NIC 13 "%0NIC %12!d! Name = %10!s! "
  188. {
  189. NICName, ItemWChar[256] //10
  190. Index, ItemULong //11
  191. PhysicalAddrLen, ItemULong //12
  192. PhysicalAddr, ItemWChar[8] //13
  193. Size, ItemULong //14
  194. IpAddress, ItemLong //15
  195. SubnetMask, ItemLong //16
  196. DhcpServer, ItemLong //17
  197. Gateway, ItemLong //18
  198. PrimaryWinsServer, ItemLong //19
  199. SecondaryWinsServer, ItemLong //20
  200. DnsServer1, ItemLong //21
  201. DnsServer2, ItemLong //21
  202. DnsServer3, ItemLong //23
  203. DnsServer4, ItemLong //24
  204. Data, ItemULong
  205. }
  206. #typev Video 14 "%0Video %17!s!"
  207. {
  208. MemorySize, ItemULong //10
  209. XResolution, ItemULong //11
  210. YResolution, ItemULong //12
  211. BitsPerPixel, ItemULong //13
  212. VRefresh, ItemULong //14
  213. ChipType, ItemWCHAR[256] //15
  214. DACType, ItemWCHAR[256] //16
  215. AdapterString, ItemWCHAR[256] //17
  216. BiosString, ItemWCHAR[256] //18
  217. DeviceId, ItemWCHAR[256] //19
  218. StateFlags, ItemULong
  219. }
  220. #typev Services 15 "%0Service (PID=%13!d!) %10!s! %11!s! %12!s!"
  221. {
  222. ServiceName, ItemWCHAR[34]
  223. DisplayName, ItemWCHAR[256]
  224. ProcessName, ItemWCHAR[34]
  225. ProcessId, ItemULong
  226. }
  227. #typev Power 16 "%0Power Configuration"
  228. {
  229. S1, ItemBool
  230. S2, ItemBool
  231. S3, ItemBool
  232. S4, ItemBool
  233. S5, ItemBool
  234. Pad1, ItemChar
  235. Pad2, ItemChar
  236. Pad3, ItemChar
  237. }
  238. 3d6fa8d4-fe05-11d0-9dda-00c04fd7ba7c DiskIo
  239. #typev Read 10 "%0Read of %12!5d! bytes (FileObj=0x%15!08X!)"
  240. #typev Write 11 "%0Write of %12!5d! bytes (FileObj=0x%15!08X!)"
  241. {
  242. Disk Number, ItemULong
  243. Irp Flags, ItemULongX
  244. Transfer Size, ItemULong
  245. QueueDepth, ItemULong
  246. Byte Offset, ItemLongLong
  247. File Object, ItemULongX
  248. }
  249. AE53722E-C863-11d2-8659-00C04FA321A1 Registry
  250. #typev Create 10 "%0Create of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  251. #typev Open 11 "%0Open of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  252. #typev Delete 12 "%0Delete of Handle = 0x%11!08X!(%14!s!) Status = %10!0X!"
  253. #typev Query 13 "%0Query of (%14!s!) Handle = 0x%11!08X! Status = %10!0X!"
  254. #typev SetValue 14 "%0SetValue of %14!s! Handle = 0x%11!08X!(%14!s!)8X! Status = %10!0X! (TID =%3!0X!)"
  255. #typev QueryValue 16 "%0QueryValue of (%14!s!) Handle = 0x%11!08X! Status = %10!0X!"
  256. #typev EnumerateKey 17 "%0EnumerateKey of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  257. #typev EnumerateValueKey 18 "%0EnumerateValueKey of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  258. #typev QueryMultipleValue 19 "%0QueryMultiple of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  259. #typev SetInformation 20 "%0SetInformation of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  260. #typev Flush 21 "%0Flush of %14!s! Handle = 0x%11!08X! Status = %10!0X!"
  261. #typev RunDown 22 "%0Rundown"
  262. {
  263. Status,ItemUlongX
  264. Key Handle, ItemULongX
  265. Elapsed Time, ItemLongLong
  266. Index, ItemULong
  267. KeyName, ItemWString
  268. }
  269. 90cbdc39-4a3e-11d1-84f4-0000f80464e3 FileIo
  270. #typev Name 0 "%0Filio for %11 (FileObj=0x%10!X!)"
  271. #typev FileCreate 32 "%0File Create of %11 (FileObj=0x%10!X!)"
  272. {
  273. File Object, ItemPtr
  274. File Name, ItemWString
  275. }
  276. 9a280ac0-c8e0-11d1-84e2-00c04fb998a2 TcpIp
  277. #typev Send 10 "%0TCPIP Send to %12!13s!:%14!05d! from %13!13s!:%15!05d! of %11!5d! bytes"
  278. #typev Recv 11 "%0TCPIP Receive from %12!13s!:%14!05d! to %13!13s!:%15!05d! of %11!5d! bytes"
  279. #typev Connect 12 "%0TCPIP Connect to %12:%14!05d! from %13:%15!05d!"
  280. #typev Disconnect 13 "%0TCPIP Discon From %12:%14!05d! to %13:%15!05d!"
  281. #typev Retransmit 14 "%0TCPIP Retransmit to %12:%14!05d!"
  282. #typev Accept 15 "%0TCPIP Accept From %12:%14!05d!"
  283. #typev Reconnect 16 "%0TCPIP Reconnect To %12:%14!05d!"
  284. {
  285. PID, ItemULong /10
  286. size, ItemULong /11
  287. daddr, ItemIPAddr /12
  288. saddr, ItemIPAddr /13
  289. dport, ItemUshort /14
  290. sport, ItemUshort /15
  291. }
  292. bf3a50c5-a9c9-4988-a005-2df0b7c80f80 UdpIp
  293. #typev Send 10 "%0UDP Send to %12!13s!:%14!05d! from %13!13s!:%15!05d! of %11!5d! bytes (Pid= %10!08X!)"
  294. #typev Recv 11 "%0UDP Receive from %12!13s!:%14!05d! to %13!13s!:%15!05d! of %11!5d! bytes (Pid= %10!08X!)"
  295. {
  296. PID, ItemULong /10
  297. size,ItemUlong /11
  298. destaddr, ItemIPAddr /12
  299. srcdaddr, ItemIPAddr /13
  300. destport, ItemUshort /14
  301. srcport, ItemUshort /15
  302. }
  303. //******************************************
  304. // Test Events
  305. // d58c126f-b309-11d1-969e-0000f875a5bc
  306. //******************************************
  307. ce5b1020-8ea9-11d0-a4ec-00a0c9062910 TraceDp
  308. #typev Start 1
  309. #typev End 2
  310. {
  311. UserData, ItemULong
  312. }
  313. f2e0e060-bf32-4b88-b8e4-5cad15af6ae9 ACPI
  314. #typev One 1 "%0%10!s!"
  315. {
  316. String,ItemString
  317. }
  318. #typev two 2 "%0%10!s!"
  319. {
  320. String,ItemString
  321. }