[install-section-name] |
[install-section-name.nt] |
[install-section-name.ntx86] |
[install-section-name.ntia64]
[DriverVer=mm/dd/yyyy[,x.y.v.z] ]
[CopyFiles=@filename | file-list-section[,file-list-section] ...]
[CopyINF=filename1.inf[,filename2.inf]...]
[AddReg=add-registry-section[,add-registry-section]...]
[Include=filename1.inf[,filename2.inf]...]
[Needs=inf-section-name[,inf-section-name]...]
[Delfiles=file-list-section[,file-list-section]...]
[Renfiles=file-list-section[,file-list-section]...]
[DelReg=del-registry-section[,del-registry-section]...]
[BitReg=bit-registry-section[,bit-registry-section]...]
[LogConfig=log-config-section[,log-config-section]...]
[ProfileItems=profile-items-section[,profile-items-section]...]
[UpdateInis=update-ini-section[,update-ini-section]...]
[UpdateIniFields=update-inifields-section[,update-inifields-section]...]
[Ini2Reg=ini-to-registry-section[,ini-to-registry-section]...]
[RegisterDlls=register-dll-section[,register-dll-section]...]
[UnregisterDlls=unregister-dll-section[,unregister-dll-section]...]
[ExcludeID=device-identification-string[,device-identification-string]...] ...
Each per-Models DDInstall section contains an optional DriverVer directive and one or more directives referencing additional named sections in the INF file, shown here with the most commonly specified INF directives, CopyFiles and AddReg, listed first. The sections referenced by these directives contain instructions for installing driver files and writing any device-specific and/or driver-specific information into the registry.
For information about how to specify this entry, see INF DriverVer Directive.
The DefaultDestDir entry in the DestinationDirs section of the INF specifies the destination for any single file to be copied. The SourceDisksNames and SourceDisksFiles sections, or an additional INF specified in the LayoutFile entry of this INF's Version section, provides the location on the distribution media of the driver files.
For more information, see INF CopyFiles Directive.
For more information, see INF CopyINF Directive.
An HKR specification in such an add-registry section designates the ..Class\SetupClassGUID\device-instance-id registry path to the user-accessible driver (a.k.a. "software" key).
For more information, see INF AddReg Directive.
For example, the system INF files for device drivers that depend on the system's kernel-streaming support specify this entry as
Include= ks.inf[, [kscaptur.inf,] [ksfilter.inf]].
(For further information on the Include entry and restrictions on its use, see Specifying the Source and Target Locations for Device Files).
For example, the INF files for device drivers that have the preceding Include entry specify this entry as
Needs= KS.Registration[, KSCAPTUR.Registration |
KSCAPTUR.Registration.NT, MSPCLOCK.Installation]
Needs entries cannot be nested. (For further information on the Needs entry and restrictions on its use, see Specifying the Source and Target Locations for Device Files).
For more information, see INF DelFiles Directive.
For more information, see INF RenFiles Directive.
Typically, this directive is used to handle upgrades when an INF must clean up old registry entries from a previous installation of this device. An HKR specification in such a delete-registry section designates the ..Class\SetupClassGUID\device-instance-id registry path to the user-accessible driver (a.k.a. "software" key).
For more information, see INF DelReg Directive.
For more information, see INF BitReg Directive.
The LogConfig directive is never used to install PnP devices. However, you can use an INF DDInstall.ConfigOverride section to provide an override configuration for PnP devices.
This directive is irrelevant to all higher level (nondevice) drivers and components.
For more information, see INF LogConfig Directive.
This directive is only supported on Windows 2000 and later platforms.
For more information, see INF ProfileItems Directive.
For more information, see INF UpdateInis Directive.
For more information, see INF UpdateIniFields Directive.
For more information, see INF Ini2Reg Directive.
For more information, see INF RegisterDlls Directive.
For more information, see INF UnregisterDlls Directive.
Throughout DDK documentation, the term DDInstall is used to refer to an install-section-name, with or without platform extensions. Thus, "DDInstall section" means "a named section within an INF, having the format [install-section-name] or [install-section-name.ntxxx]". When you create names for DDInstall sections, you should include a device-specific prefix, such as [WDMPNPB003_Device] or [GPR400.Install.NT].
Each DDInstall section must be referenced in a device/models-specific entry under the per-manufacturer INF Models section of the INF file.
Except for devices that have no associated files to be transferred from the source media, a dual-OS INF file for a WDM driver must have at least two parallel DDInstall sections for a given device, as follows:
For more information about how to use the system-defined .nt, .ntx86, and .ntia64 extensions, see Creating INF Files for Multiple Platforms and Operating Systems.
If a Windows 2000 or later INF file installs drivers, it must have DDInstall.Services sections to specify device/driver registry information to be stored in the registry's ...\CurrentControlSet\Services tree. Depending on the device, it can also have one or more DDInstall.HW, DDInstall.CoInstallers, DDInstall.Interfaces, and/or DDInstall.LogConfigOverride sections.
Each directive in a DDInstall section can reference more than one section name, but each additional named section must be separated from the next with a comma (,). Each such section name must be unique within the INF and must follow the general rules for defining section names. These rules are described in General Syntax Rules for INF Files.
Any AddReg directive specified in a DDInstall section is assumed to reference an add-registry section that cannot be used to store information about upper or lower filter drivers, about multifunction devices, or about driver-independent but device-specific parameters. If a device/driver INF must store this type of information in the registry, it must use an AddReg directive in its undecorated and decorated DDInstall.HW sections, if any, to reference another INF-writer-defined add-registry-section.
A DDInstall section can include a directive named Reboot or Restart. These directives are only for compatibility with Windows 9x. If one of these entries is present the OS is forced to reboot when the device is installed. These directives should never be used for PnP devices. In any case, it is best to let Setup determine whether the machine needs to be rebooted rather than specifying these directives.
This example shows the expansion of the DDInstall sections, Ser_Inst and Inp_Inst These sections are referenced in the example for the INF Models section.
[Ser_Inst] CopyFiles=Ser_CopyFiles, mouclass_CopyFiles [Ser_CopyFiles] sermouse.sys [mouclass_CopyFiles] ; section name referenced by > 1 CopyFiles mouclass.sys [Inp_Inst] CopyFiles=Inp_CopyFiles, mouclass_CopyFiles [Inp_CopyFiles] inport.sys
The following example provides a general illustration of using platform extensions
[Manufacturer] %MSFT% = Microsoft [Microsoft] %Device.DeviceDesc% = DeviceInstall, HWID [DeviceInstall.NTx86] ; ; This section is used for installations on NT-based x86 systems. ; ... [DeviceInstall.NTx86.Services] ; ; Services installation for NT-based x86 systems. ; ... [DeviceInstall.NT] ; ; This section is used for installations on NT-based systems (all other architectures). ; ... [DeviceInstall.NT.Services] ; ; Services installation for NT-based systems (all other architectures). ; ... [DeviceInstall] ; ; This section is used for installations on non-NT-based platforms (that is, Win9x/WinME). ; ...
This example shows the DDInstall section in a dual-OS INF file, for installation of a system-supplied WDM driver for an audio device, on an NT-based system. With the exception of the DriverVer directive, this section's entries are identical to the undecorated DDInstall section for installations of the same device on Windows 9x/Me platforms. However, this install-section-name.NT section is necessary in such a dual-OS INF file to set up the install-section-name.NT.Services section that is required to install the device and driver on Windows 2000 and later platforms.
[WDMPNPB003_Device.NT] DriverVer=01/14/1999,5.0 Include=ks.inf, wdmaudio.inf Needs=KS.Registration, WDMAUDIO.Registration.NT LogConfig=SB16.LC1,SB16.LC2,SB16.LC3,SB16.LC4,SB16.LC5 ; a few log-config-sections omitted here for brevity CopyFiles=MSSB16.CopyList AddReg=WDM_SB16.AddReg
The following shows the sections referenced by the preceding Needs entry in the system-supplied ks.inf and wdmaudio.inf files specified in the Include entry. When an NT-based system's device installer and/or media class installer process this device's install-section-name.NT section, these next two sections are also processed.
[KS.Registration] ; following AddReg= is actually a single line in the ks.inf file AddReg=ProxyRegistration,CategoryRegistration,\ TopologyNodeRegistration,PlugInRegistration,PinNameRegistration,\ DeviceRegistration CopyFiles=KSProxy.Files,KSDriver.Files [WDMAUDIO.Registration.NT] AddReg=WDM.AddReg CopyFiles=WDM.CopyFiles.Sys, WDM.CopyFiles.Drv ; ; INF-writer-defined add-registry and file-list sections ; referenced by preceding directives are omitted here for brevity ;
INF DDInstall.CoInstallers Section
INF DDInstall.FactDef Section
INF DDInstall.HW Section
INF DDInstall.Interfaces Section
INF DDInstall.LogConfigOverride Section
INF DDInstall.Services Section
INF DefaultInstall Section
INF DefaultInstall.Services Section