Post · 4 min read· pp. 2455–2458

NTCONFIG.H

The public symbol file NTKRPAMP.PDB for the original release of Windows 10 tells that the kernel is built with the NTCONFIG.H header at

d:\th.public.fre\internal\sdk\inc

and draws from it the following type definitions:

Line NumberTypeWDM.HRemarks
249enum _CM_SHARE_DISPOSITION9465
393struct _CM_PARTIAL_RESOURCE_DESCRIPTOR9603loses 6
397unnamed union for u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9607
405unnamed struct for Generic in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9615
418unnamed struct for Port in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9623loses 5
430unnamed struct for Interrupt in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9631loses 4
446unnamed struct for MessageInterrupt in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9647
448unnamed struct for Raw in MessageInterrupt in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9649
459unnamed struct for Translated in MessageInterrupt in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9660
478unnamed struct for Memory in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9679
487unnamed struct for Dma in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9688
493unnamed struct for DmaV3 in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9694
507unnamed struct for DevicePrivate in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9708
515unnamed struct for BusNumber in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9716
528unnamed struct for DeviceSpecificData in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9729
536unnamed struct for Memory40 in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9737
541unnamed struct for Memory48 in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9742
546unnamed struct for Memory64 in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9747
551unnamed struct for Connection in u in _CM_PARTIAL_RESOURCE_DESCRIPTOR9752
575struct _CM_PARTIAL_RESOURCE_LIST9776
599struct _CM_FULL_RESOURCE_DESCRIPTOR9794loses 6
610struct _CM_RESOURCE_LIST9805
1135enum _IRQ_PRIORITY10296loses 34
1155struct _IO_RESOURCE_DESCRIPTOR10316
1163unnamed union for  u in _IO_RESOURCE_DESCRIPTOR10324
1164unnamed struct for Port in u in _IO_RESOURCE_DESCRIPTOR10325
1171unnamed struct for Memory in u in _IO_RESOURCE_DESCRIPTOR10332
1178unnamed struct for Interrupt in u in _IO_RESOURCE_DESCRIPTOR10339
1191unnamed struct for Dma in u in _IO_RESOURCE_DESCRIPTOR10352
1196unnamed struct for DmaV3 in u in _IO_RESOURCE_DESCRIPTOR10357
1203unnamed struct for Generic in u in _IO_RESOURCE_DESCRIPTOR10364
1210unnamed struct for DevicePrivate in u in _IO_RESOURCE_DESCRIPTOR10371
1218unnamed struct for BusNumber in u in _IO_RESOURCE_DESCRIPTOR10379
1225unnamed struct for ConfigData in u in _IO_RESOURCE_DESCRIPTOR10386
1236unnamed struct for Memory40 in u in _IO_RESOURCE_DESCRIPTOR10397
1243unnamed struct for Memory48 in u in _IO_RESOURCE_DESCRIPTOR10404
1250unnamed struct for Memory64 in u in _IO_RESOURCE_DESCRIPTOR10411
1257unnamed struct for Connection in u in _IO_RESOURCE_DESCRIPTOR10418
1271struct _IO_RESOURCE_LIST10432
1280struct _IO_RESOURCE_REQUIREMENTS_LIST10441

The header NTCONFIG.H is not known in any Device Driver Kit (DDK) or Windows Driver Kit (WDK).

That said, all the types that the kernel is known to pick up from NTCONFIG.H are defined in the standard header WDM.H. The line numbers on the left are from NTCONFIG.H, as inferred from the public symbol file for the kernel. Those on the right are from WDM.H, as readily available in the WDK for Windows 10. It is not known whether NTCONFIG.H is the source of definitions in WDM.H or whether both pick them up from yet another header.

What is clear, though, is that WDM.H is a consistent loser of lines. NTCONFIG.H, which Microsoft keeps to itself, has more of this material than does WDM.H. What the extra is, let alone whether it’s important, is not easily assessed without an NTCONFIG.H for inspection, but one inference that’s possible seems sound. Given that the type information for the CM_PARTIAL_RESOURCE_DESCRIPTOR in the symbol file is what the kernel used from NTCONFIG.H, then since it agrees with the definition in WDM.H, the definition in NTCONFIG.H can’t differ in substance. Its five extra lines between the Generic and Port members and four between Port and Interrupt are plausibly just comments. Of course, this does prompt a question: what does Microsoft have to say by way of introducing Port and Interrupt that should be known by its own programmers but not by others?

For the record, Microsoft’s freely published URLMON.PDB reveals that all the preceding, and the very many more that follow, were accessible to the source code for URLMON.DLL from including NTCONFIG.H when building for the original release of 32-bit Windows 10:

Line NumberType
627struct _DEVICE_FLAGS
641struct _CM_COMPONENT_INFORMATION
662struct _CM_ROM_BLOCK
677struct _CM_INT13_DRIVER_PARAMETER
691struct _CM_MCA_POS_DATA
703struct _EISA_MEMORY_TYPE
713struct _EISA_MEMORY_CONFIGURATION
726struct _EISA_IRQ_DESCRIPTOR
734struct _EISA_IRQ_CONFIGURATION
744struct _DMA_CONFIGURATION_BYTE0
751struct _DMA_CONFIGURATION_BYTE1
758struct _EISA_DMA_CONFIGURATION
768struct _EISA_PORT_DESCRIPTOR
775struct _EISA_PORT_CONFIGURATION
787struct _CM_EISA_SLOT_INFORMATION
803struct _CM_EISA_FUNCTION_INFORMATION
837struct _CM_PNP_BIOS_DEVICE_NODE
851struct _CM_PNP_BIOS_INSTALLATION_CHECK
920struct _CM_SCSI_DEVICE_DATA
934struct _CM_VIDEO_DEVICE_DATA
944struct _CM_SONIC_DEVICE_DATA
955struct _CM_SERIAL_DEVICE_DATA
969struct _CM_MONITOR_DEVICE_DATA
1003struct _CM_FLOPPY_DEVICE_DATA
1040struct _CM_KEYBOARD_DEVICE_DATA
1052struct _CM_DISK_GEOMETRY_DEVICE_DATA
1065struct _CM_PCCARD_DEVICE_DATA
1120enum _IRQ_DEVICE_POLICY
1146enum _IRQ_GROUP_POLICY