Inf file windows version

Using a Component INF File

If you want to include user-mode software for use with a device on Windows 10, you have the following options to create a DCH-compliant driver:

Method Scenario
Hardware support apps (HSA) Device add-on software packaged as a UWP app that is delivered and serviced from the Microsoft Store. Recommended approach.
Software components Device add-on software is an MSI or EXE binary, a Win32 service, or software installed using AddReg and CopyFiles. Referenced binary only runs on desktop editions (Home, Pro, and Enterprise). The referenced binary will not run on Windows 10S.

A software component is a separate, standalone driver package that can install one or more software modules. The installed software enhances the value of the device, but is not necessary for basic device functionality and does not require an associated function driver service.

This page provides guidelines for the use of software components.

Getting started

To create components, an extension INF file specifies the INF AddComponent directive one or more times in the INF DDInstall.Components section. For each software component referenced in an extension INF file, the system creates a virtual software-enumerated child device. More than one driver package can reference the same software component.

Virtual device children can be updated independently just like any other device, as long as the parent device is started. We recommend separating functionality into as many different groupings as makes sense from a servicing perspective, and then creating one software component for each grouping.

You’ll provide an INF file for each software component.

If your software component INF specifies the AddSoftware directive, the component INF:

  • Must be a universal INF file.
  • Must specify the SoftwareComponent setup class.

You can specify the AddSoftware directive one or more times.

When using Type 2 of the AddSoftware directive, it is not required to utilize a Component INF. The directive can be used in any INF successfully. An AddSoftware directive of Type 1, however, must be used from a Component INF.

Additionally, any INF (component or not) matching on a software component device:

  • Can specify Win32 user services using the AddService directive.
  • Can install software using the INF AddReg directive and the INF CopyFiles directive.
  • Does not require a function driver service.
  • Can be uninstalled by the user independently from the parent device.

You can find an example of a component INF in the Driver package installation toolkit for universal drivers.

Note: In order for a software-enumerated component device to function, its parent must be started. If there is no driver available for the parent device, driver developers can create their own and optionally leverage the pass-through driver «umpass.sys». This driver is included in Windows and, effectively, does nothing other than start the device. In order to use umpass.sys, developers should use the Include/Needs INF directives in the DDInstall section for each possible [DDInstall.*] section to the corresponding [UmPass.*] sections as shown below, regardless of whether the INF specifies any directives for that section or not:

Accessing a device from a software component

To retrieve the device instance ID of a device that is associated with a software component, use the SoftwareArguments value in the INF AddSoftware directive section with the > runtime context variable.

The executable can then retrieve the device instance ID of the software component from its incoming argument list.

Next, if the software component is targeting the Universal target platform, use the following procedure:

  1. Call CM_Locate_DevNode with the device instance ID of the software component to retrieve a device handle.
  2. Call CM_Get_Parent to retrieve a handle to that device’s parent. This parent is the device that added the software component using the INF AddComponent Directive.
  3. Then, to retrieve the device instance ID of the parent, call CM_Get_Device_ID on the handle from CM_Get_Parent.

If the software component is targeting the Desktop target platform only, use the following procedure:

  1. Call SetupDiCreateDeviceInfoList to create an empty device information set.
  2. Call SetupDiOpenDeviceInfo with the software component device’s device instance ID.
  3. Call SetupDiGetDeviceProperty with DEVPKEY_Device_Parent to retrieve the device instance ID of the parent.

Example

The following example shows how you might use a software component to install a control panel using an executable for a graphics card.

Driver package INF file

Software component INF file

The driver validation and submission process is the same for component INFs as for regular INFs. For more info, see Windows HLK Getting Started.

INF – Файл конфигурации установки программ (Setup Information File)

Расширение INF

Чем открыть файл INF

В Windows: Microsoft Windows, Блокнот, NotePad++, Любой текстовый редактор
В Mac OS: MacroMates TextMate, Любой текстовый редактор

Описание расширения INF

Популярность:

Расширение INF – это текстовый файл, который содержит информацию об устройствах и файлах для установки, например, образы драйверов, информация о реестре, расположение файлов и директорий, информация о версии и так далее, всё, что используется компонентами установки.

.INF состоит из множества названных секций, каждая из которых содержит одну или более позиций. Каждый раздел начинается с имени секции в квадратных скобках. Разделы имеют определенную цель (например, для копирования файлов или добавить записи в реестр) и содержат элементы, имеющие вид Имя=Значение. INF-файлы по сути похожи на INI-файлы. Файлы INF в основном используются для установки драйверов и системных инсталляционных пакетов Microsoft Windows, но так же могут быть использованы и для установки других приложений.

ПРИМЕЧАНИЕ: Файлы INF могут содержать вирусы, поэтому если вам по почте пришел .INF файл, то его не рекомендуется открывать.

ПРИМЕЧАНИЕ: Самый известный INF-файл – это Autorun.inf, используемый для автоматического запуска или установки приложений в операционной системе Windows (начиная с версии Windows 95). Этот файл должен находиться в корневом каталоге файловой системы устройства, для которого осуществляется автозапуск.

MIME тип: application/inf
HEX код: 5B 61 75 74 6F 72 75 6E 5D 0D 0A
ASCII код: [autorun]

Другие программы, связанные с расширением INF

    Информационный файл Adobe Type Manager от Adobe Systems Incorporated
    Расширение .INF – файл, который хранит информацию, связанную со шрифтами Type 1. .INF файл открывается в программе Adobe Type Manager для Apple Mac и Microsoft Windows.

Популярность:

    Временный файл Pro/ENGINEER от Parametric Technology Corporation
    Расширение INF связано с приложением Pro/ENGINEER (так же известным как Creo Elements/Pro) 3D CAD/CAM/CAE программным обеспечением. .INF файл хранит временные данные, созданные приложением Pro/Engineer.

    Популярность:

    Файл цвета нитей Bernina от Bernina
    Расширение .INF – это файл, который хранит информацию о цвете нитей для соответствующего файла с дизайном вышивки .EXP. Файл INF используется в приложении ArtLink для вышивальных машин Bernina.

    Относится к разделу Другие файлы.

    Популярность:

The MTP Setup Information (.inf) File

Microsoft provides a set of class drivers to support the Media Transfer Protocol (MTP). If your device supports MTP, you can use one of these drivers. In addition to the class drivers, Microsoft provides a setup information (.inf) file to install a class driver. This file is named WpdMtp.inf.

If your MTP device has unique requirements, create a new setup information (.inf) file that is based on the original version of WpdMtp.inf. (You cannot modify WpdMtp.inf directly.)

The following table describes specific Needs directives that are found in WpdMtp.inf and possible modifications that you can make to the sections that are identified by a given directive.

The entries in the following table can support any of three transports (USB, IP, or Bluetooth). Be aware that each transport requires a unique installation section. Also be aware that the Bluetooth transport is only supported in Windows 7.

Needs directive Description
Needs = WPD.MTP, WINUSB.NT The WPD.MTP section identifies the driver files that will be copied and registered. The following applies to Windows Vista and Windows Media Player 11.

Starting with Windows 7, WinUsb.sys replaces WpdUsb.sys as the lower filter driver for MTP devices that connect to the computer by using USB. The following directive is required for a vendor’s INF to include WinUsb.inf and a specific WinUSB section:

Needs = WPD.MTP.Registration The WPD.MTP.Registration section accomplishes four tasks:
  1. Registers the kernel-mode driver (including WPDUSB.sys as the lower filter driver if you are installing the device on Windows Vista or Windows XP).
  2. Enables default MTP AutoPlay support.
  3. Enables legacy application compatibility support (the default value 0xFFFFFFFF allows the WPD class installer to query the device’s capabilities).
  4. Sets the transport driver’s class identifier.
Needs = WPD.MTP.Registration.Basic The WPD.MTP.Registration.Basic section lets you customize tasks 2 and 3 in the previous list. For example, you can set the application compatibility to support Windows Image Acquisition (WIA) by using a value of 0x01 or Windows Media Device Manager (WMDM) by using a value of 0x02.
Needs = WPD.MTP.Services The WPD.MTP.Services section adds driver services (and default service parameters). This includes WUDF and WPDUSB.sys (for Windows Vista and Windows XP only).
Needs = WPD.MTP.CoInstallers The WPD.MTP.CoInstallers section identifies the co-installer. (To install an MTP device, a Windows user-mode driver framework (UMDF) co-installer is used.)

This section is required for Windows 7, Windows Vista, and Windows Media Player 11. (It was not required for an MTP driver that supported Windows Media Player 10.)

Needs = WPD.MTP.Wdf The WPD.MTP.Wdf section identifies the Windows user-mode driver framework (UMDF) service and its binary (WPDMTPDR.dll).

This section is required for Windows 7, Windows Vista, and Windows Media Player 11. (It was not required for an MTP driver that supported Windows Media Player 10.)

INF File Platform Extensions and x64-Based Systems

Platform Extensions and x64-Based Systems (Windows XP and later)

On Windows Server 2003 Service Pack 1 (SP1) and later, an .ntamd64 platform extension is required on an INF Models section. An .ntamd64 or .nt platform extension is optional on all other sections that support platform extensions.

For sections that support optional platform extensions, Windows selects which section to process, as follows:

Windows checks for a section-name.ntamd64 section and, if one exists, processes it. Windows checks for the .ntamd64 extension in the INF file that is being processed and in any included INF files (that is, any INF files that are included with Include entries).

If a section-name.ntamd64 section does not exist, Windows checks for a section-name.nt section in the INF file or any included INF files. If one exists, Windows processes the section-name.nt section.

If a section-name.nt section does not exist, Windows processes a section-name section that does not include a platform extension.

Testing Installation on x64-Based Systems (Windows Server 2003 SP1 and Later)

For testing purposes only, the requirement that an INF Models section name include an .ntamd64 extension can be suppressed. To suppress this requirement, create the following registry value entry under the subkey HKLM\Software\Microsoft\Windows\CurrentVersion\Setup and set this value entry to one:

After setting the DisableDecoratedModelsRequirement value entry to one, restart the system and then install the device.

To restore the platform extension requirement, delete the DisableDecoratedModelsRequirement value entry or set it to zero, and then restart the system.

Creating INF Files for x64-Based Systems (Windows XP and later)

In general, you cannot use a single INF file that differentiates between device installations that are based on the operating system version. For example, if the files or registry settings that support a device differ between versions of x64-based operating systems, you must create an operating system-specific INF file for each version.

However, if a device does not require an operating system-specific installation, you can create a single cross-operating system INF file for x64-based systems that run Windows XP and later.

Because Windows Server 2003 SP1 and later require an .ntamd64 platform extension on an INF Models section name, but do not require this extension on other section names, the simplest approach to create and to maintain a cross-operating system INF file for x64-based systems is to include the .ntamd64 extension only on the names of Models sections.

To create such a cross-operating system INF file, do the following:

Create a valid INF file that contains the generic entries that are required in all INF files, as described in General Guidelines for INF Files.

Include an INF Manufacturer section that includes a manufacturer-identifier that specifies the INF Models section name for the device and that specifies the .ntamd64 platform extension. For example, the following Manufacturer section specifies an INF Models section name of «AbcModelSection» for an Abc device and the .ntamd64 platform extension.

Include a Models.ntamd64 section whose name matches the Models section name that is specified by the manufacturer-identifier in the Manufacturer section. For example, the following AbcModelSection.ntamd64 section for an Abc device includes a device-description that specifies an install-section-name of «AbcInstallSection.»

Include a DDInstall section whose name matches the install-section-name that is specified by the Models section. For example, the device-description in an AbcModelSection section specifies the following AbcInstallSection section for an Abc device.

Include other device-specific sections that are required to install the device, but do not include an .ntamd64 platform extension on names of these sections. For more information about INF file sections and directives, see Summary of INF Sections and Summary of INF Directives.

For information about how to create a single cross-operating system INF for all platform types, see Cross-Platform INF Files.

Читайте также:  Microsoft essentials security windows не устанавливается
Оцените статью