Skip to content

Commit

Permalink
Update Windows driver INF file according to latest best practices
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristopherMann committed Jan 26, 2024
1 parent 9cec695 commit d31f8a9
Showing 1 changed file with 47 additions and 25 deletions.
72 changes: 47 additions & 25 deletions datapath-windows/ovsext/ovsext.inf
Original file line number Diff line number Diff line change
Expand Up @@ -8,47 +8,55 @@ Class = NetService
ClassGUID = {4D36E974-E325-11CE-BFC1-08002BE10318}
Provider = %OVS%
CatalogFile = DBO_OVSE.cat
DriverVer = 10/10/2013,1.0
DriverVer = 10/10/2013,1.0.0.0
PnpLockdown = 1

[Manufacturer]
%OVS%=OVS,NTx86,NTia64,NTamd64
%OVS%=OVS,NTamd64,NTamd64.10.0...16299

[OVS.NTx86]
%DBO_OVSE_Desc%=Install, DBO_OVSE

[OVS.NTia64]
%DBO_OVSE_Desc%=Install, DBO_OVSE
; Model section for Windows 1709 (Build 16299) or newer
[OVS.NTamd64.10.0...16299]
%DBO_OVSE_Desc% = OVS_Install, DBO_OVSE

; Model section for older versions of Windows
[OVS.NTamd64]
%DBO_OVSE_Desc%=Install, DBO_OVSE
%DBO_OVSE_Desc% = OVS_Install_Fallback, DBO_OVSE

;-------------------------------------------------------------------------
; Installation Section
;-------------------------------------------------------------------------
[Install]
AddReg=Inst_Ndi
Characteristics=0x40000
NetCfgInstanceId="{63E968D9-754E-4704-A5CE-6E3BF7DDF59B}"
Copyfiles = DBO_OVSE.copyfiles.sys
[OVS_Install]
AddReg = OVS_Install_Ndi
Characteristics = 0x40000
NetCfgInstanceId = "{63E968D9-754E-4704-A5CE-6E3BF7DDF59B}"
Copyfiles = OVS_Install_Files

[OVS_Install_Fallback]
AddReg = OVS_Install_Ndi
Characteristics = 0x40000
NetCfgInstanceId = "{63E968D9-754E-4704-A5CE-6E3BF7DDF59B}"
Copyfiles = OVS_Install_Fallback_Files

[SourceDisksNames]
1=%DBO_OVSE_Desc%,"",,
1 = %DBO_OVSE_Desc%

[SourceDisksFiles]
DBO_OVSE.sys=1
DBO_OVSE.sys = 1

[DestinationDirs]
DefaultDestDir=12
DBO_OVSE.copyfiles.sys=12
OVS_Install_Files = 13
OVS_Install_Fallback_Files = 12

[DBO_OVSE.copyfiles.sys]
[OVS_Install_Files]
DBO_OVSE.sys,,,2

[OVS_Install_Fallback_Files]
DBO_OVSE.sys,,,2

;-------------------------------------------------------------------------
; Ndi installation support
;-------------------------------------------------------------------------
[Inst_Ndi]
[OVS_Install_Ndi]
HKR, Ndi,Service,,"DBO_OVSE"
HKR, Ndi,CoServices,0x00010000,"DBO_OVSE"
HKR, Ndi,HelpText,,%DBO_OVSE_HelpText%
Expand All @@ -60,13 +68,27 @@ HKR, Ndi\Interfaces, FilterMediaTypes,,"vmnetextension"
HKR, Ndi,FilterRunType, 0x00010001, 2 ; optional

;-------------------------------------------------------------------------
; Service installation support, common.EventLog here is to demonstrate how to
; write an enent log
; Service installation
;-------------------------------------------------------------------------
[Install.Services]
AddService=DBO_OVSE,,DBO_OVSE_Service_Inst;, common.EventLog
[OVS_Install.Services]
AddService = DBO_OVSE,,OVS_Install_AddService

[OVS_Install_AddService]
DisplayName = %DBO_OVSE_Desc%
ServiceType = 1 ;SERVICE_KERNEL_DRIVER
StartType = 1 ;SERVICE_SYSTEM_START
ErrorControl = 1 ;SERVICE_ERROR_NORMAL
ServiceBinary = %13%\DBO_OVSE.sys
LoadOrderGroup = NDIS
Description = %DBO_OVSE_Desc%

[OVS_Install.Remove.Services]
DelService=DBO_OVSE,0x200

[OVS_Install_Fallback.Services]
AddService = DBO_OVSE,,OVS_Install_Fallback_AddService

[DBO_OVSE_Service_Inst]
[OVS_Install_Fallback_AddService]
DisplayName = %DBO_OVSE_Desc%
ServiceType = 1 ;SERVICE_KERNEL_DRIVER
StartType = 1 ;SERVICE_SYSTEM_START
Expand All @@ -75,7 +97,7 @@ ServiceBinary = %12%\DBO_OVSE.sys
LoadOrderGroup = NDIS
Description = %DBO_OVSE_Desc%

[Install.Remove.Services]
[OVS_Install_Fallback.Remove.Services]
DelService=DBO_OVSE,0x200

[Strings]
Expand Down

0 comments on commit d31f8a9

Please sign in to comment.