PSHED プラグインの INF ファイル
PSHED プラグインは、情報 (INF) ファイルによってインストールされます。 PSHED プラグインの INF ファイルには、次の標準 INF ファイル セクションが含まれています。
INF Models セクション内で、プラットフォーム ベンダーは PSHED プラグインに任意のハードウェア識別子 (ID) を使用できます。 ハードウェア ID は、Models セクションの hw-id エントリを使用して指定され、ACPI 名前空間または別のデバイス名前空間のハードウェア ID を指定することができます。 ベンダーは、PNP0C33 の値と互換性のある ID を指定することもできます。 この互換性のある ID は、マイクロソフトと互換性のあるハードウェア エラー デバイスを定義するために使用されます。 ベンダーは、Models セクションの compatible-id エントリを使用して、互換性のある ID を指定します。
PSHED プラグインの INF ファイルには、レジストリの System\CurrentControlSet\Control\PSHED\Plugins キーにエントリを追加するファイル内のセクションを参照する AddReg ディレクティブも含める必要があります。 このエントリは、PSHED プラグインがシステムにインストールされていることを PSHED に通知します。 これにより、PSHED は、システムが起動されるたびに、インストールされているすべての PSHED プラグインが正常に読み込まれたことを確認できます。
次に例を示します。
;
; Example PSHED plug-in INF file
;
[Version]
Signature = "$Windows NT$"
Class = System ; Specify appropriate Class
ClassGuid = {4d36e97d-e325-11ce-bfc1-08002be10318} ; Specify appropriate ClassGuid
Provider = %Msft%
CatalogFile = "ExamplePSHEDPlugin.cat"
DriverVer = 01/01/06,1.0
PnpLockdown = 1
[SourceDiskNames]
1 = %DiskName%
[SourceDiskFiles]
%FileName% = 1
[DestinationDirs]
ExamplePSHEDPlugin.DriverFiles = 13
[Manufacturer]
%Msft% = Microsoft,NTamd64
[Microsoft.NTamd64]
%DeviceDesc% = ExamplePSHEDPluginInstall,%DeviceId%
[ExamplePSHEDPluginInstall]
OptionDesc = %Description%
CopyFiles = ExamplePSHEDPlugin.DriverFiles
AddReg = ExamaplePSHEDPlugin.AddReg
[ExamplePSHEDPluginInstall.Services]
AddService = %ServiceName%,,ExamplePSHEDPlugin.Service
[ExamplePSHEDPlugin.DriverFiles]
%FileName%,,,0x00000040 ; COPYFLG_OVERWRITE_OLDER_ONLY
[ExamplePSHEDPlugin.AddReg]
HKLM,%PSHEDControlPath%,%ServiceName%,0x00000000,%FileName%
[ExamplePSHEDPlugin.Service]
DisplayName = %ServiceName%
Description = %ServiceDesc%
ServiceType = 1 ; SERVICE_KERNEL_DRIVER
StartType = 3 ; SERVICE_DEMAND_START
ErrorControl = 1 ; SERVICE_ERROR_NORMAL
ServiceBinary = %13%\%FileName%
[Strings]
%Msft% = "Microsoft Corporation"
%DiskName% = "Example PSHED Plug-In Installation Disk"
%FileName% = "ExamplePSHEDPlugin.sys"
%DeviceDesc% = "Example PSHED Plug-In Device"
%DeviceId% = "ACPI\PSHEDPI"
%Description% = "Example PSHED Plug-In"
%ServiceName% = "ExamplePSHEDPlugin"
%ServiceDesc% = "Example PSHED Plug-In"
%PSHEDControlPath% = "System\CurrentControlSet\Control\PSHED\Plugins"