Muokkaa

Jaa


INF Models section

A per-manufacturer Models section identifies at least one device, references the DDInstall section of the INF file for that device, and specifies a unique-to-the-model-section Hardware identifier (ID) for that device.

Any entry in the per-manufacturer Models section can also specify one or more additional device IDs for models that are compatible with the device designated by the initial hardware ID and are controlled by the same drivers.

[models-section-name] |
[models-section-name.TargetOSVersion]  (Windows XP and later versions of Windows)

device-description=install-section-name,[hw-id][,compatible-id...]
[device-description=install-section-name,[hw-id][,compatible-id]...] ...

Note

INFs are required to specify at least one device ID for each entry in the models section. This may be either a hardware ID or compatible ID.

Entries

device-description
Identifies a device to be installed, expressed as any unique combination of visible characters or as a %strkey% token defined in an INF Strings section. The maximum length, in characters, of a device description is LINE_LEN.

install-section-name
Specifies the undecorated name of the INF install sections to be used for the device (and compatible models of device, if any). For more information, see INF DDInstall Section.

hw-id
Specifies a vendor-defined Hardware ID string that identifies a device, which the PnP manager uses to find an INF-file match for this device. Such a hardware ID has one of the following formats:

enumerator\enumerator-specific-device-id
Is the typical format for individual PnP devices reported to the PnP manager by a single enumerator. For example, USB\VID_045E&PID_00B identifies the Microsoft HID keyboard device on a USB bus. Depending on the enumerator, such a specification can even include the device's hardware revision number as, for example, PCI\VEN_1011&DEV_002&SUBSYS_00000000&REV_02.

*enumerator-specific-device-id
Indicates with the asterisk (*) that the device is supported by more than one enumerator. For example, *PNP0F01 identifies the Microsoft serial mouse, which also has a compatible-id specification of SERENUM\PNP0F01.

device-class-specific-ID
Is an I/O bus-specific format, as described in the hardware specification for the bus, for the hardware IDs of all peripheral devices on that type of I/O bus.

compatible-id
Specifies a vendor-defined compatible ID string that identifies compatible devices. Any number of compatible-id values can be specified for an entry in the Models section, each separated from the next by a comma (,). All such compatible devices and/or device models are controlled by the same driver as the device designated by the initial hw-id.

Remarks

Each models-section-name must be listed in the INF Manufacturer section of the INF file. There can be one or more entries in any per-manufacturer Models section, depending on how many devices (and drivers) the INF file installs for a particular manufacturer.

Each install-section-name must be unique within the INF file and must follow the general rules for defining section names, described in General Syntax Rules for INF Files. The DDInstall section name referenced in a per-manufacturer Models section can also have extensions appended to the given install-section-name, thus defining additional DDInstall sections for the OS-specific or platform-specific installation of the given devices. For more information about how to use extensions in cross-platform system files, see also Creating an INF File.

Any specified hw-id or compatible-id value can also be specified in the INF ControlFlags section to prevent that device from being displayed to the end-user during manual installations. For more information about hw-id and compatible-id values, see Device Identification Strings.

For each device and driver that is installed by using an INF file, the device installers use the information supplied in the INF Manufacturer section and per-manufacturer Models sections to generate Device Description, Manufacturer Name, Device ID (if the installation is manual), and, possibly, Compatibility List value entries in the registry.

A models section name can include a TargetOSVersion decoration. For more information about this decoration, see INF Manufacturer Section, specifically the Remarks section.

Important

Starting with Windows Server 2003 SP1, INF files must decorate models-section-name entries in the INF Manufacturer section, along with the associated INF Models section names, with platform extensions to specify non-x86 target operating system versions. These platform extensions are not required in INF files for x86-based target operating system versions but are recommended.

Examples

This example shows a per-manufacturer Models section with some representative entries from the system mouse class installer's INF file, defining the DDInstall sections for some devices/models.

[Manufacturer]
%StdMfg% = StdMfg,NTamd64         ; (Standard types)
%MSMfg%  = MSMfg,NTamd64          ; Microsoft
; ... %otherMfg% omitted here

[StdMfg.NTamd64]  ; per-Manufacturer Models section 
; Std serial mouse
%*pnp0f0c.DeviceDesc%= Ser_Inst,*PNP0F0C,SERENUM\PNP0F0C,SERIAL_MOUSE
; ... more StdMfg entries 

For more examples of OS-specific INF Models sections, see the Examples section of INF Manufacturer section, and also Combining platform extensions with operating system versions.

See also

Hardware identifiers (HWIds)

ControlFlags

DDInstall

Manufacturer

Strings