;/*++
;
;Copyright (c) Spreadtrum Communications Inc.  All rights reserved.
;
;Abstract:
;    INF file for the WDF USB serial driver 
;
;--*/

[version]
signature   = "$CHICAGO$"
Class       = Ports
ClassGuid   = {4D36E978-E325-11CE-BFC1-08002BE10318}
Provider    = %PROV%
DriverVer   = 11/19/2014,2.0.0.121
CatalogFile = sprd_wvcom.cat

; ================= Device Install section =====================

[ControlFlags]
ExcludeFromSelect=*

[Manufacturer]
%PROV%=PROV,NTx86,NTAMD64

[SourceDisksFiles]
sprd_wvcom.sys=1

[SourceDisksNames]
1=%DISK_NAME%,

[DestinationDirs]
DefaultDestDir  = 12

; For Win2K
[PROV]
%UI.sprd_wvcom%   = Serial_Inst, USB\VID_1782&PID_3D02&MI_01
%UI.sprd_wvcom%   = Serial_Inst, USB\VID_1782&PID_0009&MI_00
%App.sprd_wvcom%  = Serial_Inst, USB\VID_1782&PID_0009&MI_01

; For XP and later
[PROV.NTx86]
%UI.sprd_wvcom%   = Serial_Inst, USB\VID_1782&PID_3D02&MI_01
%UI.sprd_wvcom%   = Serial_Inst, USB\VID_1782&PID_0009&MI_00
%App.sprd_wvcom%  = Serial_Inst, USB\VID_1782&PID_0009&MI_01

[PROV.NTAMD64]
%UI.sprd_wvcom%   = Serial_Inst, USB\VID_1782&PID_3D02&MI_01
%UI.sprd_wvcom%   = Serial_Inst, USB\VID_1782&PID_0009&MI_00
%App.sprd_wvcom%  = Serial_Inst, USB\VID_1782&PID_0009&MI_01

[Serial_Inst.NT]
CopyFiles = Serial.CopyFiles
AddReg = Serial_Inst.AddReg

[Serial_Inst.AddReg]
HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider"

[Serial_Inst.NT.HW]
AddReg = Models_HW_AddReg

[Serial.CopyFiles]
sprd_wvcom.sys

[Serial_Inst.NT.Services]
AddService=sprd_wvcom,0x00000002,Serial_Service 

[Serial_Service]
ServiceType    = 1                  ; SERVICE_KERNEL_DRIVER
StartType      = 3                  ; SERVICE_DEMAND_START
ErrorControl   = 1                  ; SERVICE_ERROR_NORMAL
ServiceBinary  = %12%\sprd_wvcom.sys
AddReg         = Serial_Parameters_AddReg

[Models_HW_AddReg]
HKR,,"VendorRequestTimeoutValue", %REG_DWORD%, 5
HKR,,DeviceCharacteristics,0x10001,0x0100         ; Use same security checks on relative opens
HKR,,Security,,"D:P(A;;GA;;;BA)(A;;GA;;;WD)"      ; Allow generic-all access to Built-in administrators and Local system 
HKR,,"SpreadtrumVendorRequest",%REG_DWORD%,0
HKR,,"CdcControlLineState",%REG_DWORD%,1
HKR,,"UseContinuousRead",%REG_DWORD%,0
HKR,,"RxFifoSize",%REG_DWORD%,128
HKR,,"UsbEnableZLP",%REG_DWORD%,1

[Serial_Parameters_AddReg]

;-------------- WDF Coinstaller installation
[DestinationDirs]
CoInstaller_CopyFiles = 11

[Serial_Inst.NT.CoInstallers]
AddReg=CoInstaller_AddReg
CopyFiles=CoInstaller_CopyFiles

[CoInstaller_CopyFiles]
WdfCoInstaller01009.dll

[SourceDisksFiles]
WdfCoInstaller01009.dll=1 ; make sure the number matches with SourceDisksNames

[CoInstaller_AddReg]
HKR,,CoInstallers32,0x00010000, "WdfCoInstaller01009.dll,WdfCoInstaller"

[Serial_Inst.NT.Wdf]
KmdfService = sprd_wvcom, Serial_wdfsect

[Serial_wdfsect]
KmdfLibraryVersion = 1.9

[Strings]
PROV           = "Spreadtrum Communications Inc."
USBCOMM        = "Spreadtrum Generic USB COMM Device"
DISK_NAME      = "Spreadtrum USB to Serial Install Disk"
App.sprd_wvcom = "SPRD Diag"
UI.sprd_wvcom  = "SPRD AT"
REG_EXPAND_SZ  = 0x00020000 
REG_DWORD      = 0x00010001 
