[Version]
Signature="$WINDOWS NT$"
Class=Net
ClassGuid={4D36E972-E325-11CE-BFC1-08002BE10318}
Provider=%XenGplPv%
CatalogFile="xennet.cat"
DriverVer=09/25/2014,6.1.7600.16385

[DestinationDirs]
DefaultDestDir = 12

[ControlFlags]
ExcludeFromSelect=*

[Manufacturer]
%XenGplPv%=XenGplPv,NTAMD64,NTAMD64.6.0

[XenGplPv.NTAMD64]
%XenNet.DRVDESC%=XenNet_Inst_NDIS5, XEN\VIF

[XenGplPv.NTAMD64.6.0]
%XenNet.DRVDESC%=XenNet_Inst_NDIS6, XEN\VIF

[XenGplPv]
%XenNet.DRVDESC%=XenNet_Inst_NDIS5, XEN\VIF

[XenNet_Inst_NDIS5]
CopyFiles=XenNet.CopyFiles
Characteristics = 0x81 ; NCF_VIRTUAL | NCF_HAS_UI
AddReg = XenNet_Reg, XenNet_Params_Common, XenNet_Params_NDIS5
*IfType            = 6  ; Ethernet
*MediaType         = 0	; NdisMedium802_3
*PhysicalMediaType = 19	; NdisPhysicalMediumOther

[XenNet_Inst_NDIS6]
CopyFiles=XenNet.CopyFiles
Characteristics = 0x81 ; NCF_VIRTUAL | NCF_HAS_UI
AddReg = XenNet_Reg, XenNet_Params_Common, XenNet_Params_NDIS6
*IfType            = 6  ; Ethernet
*MediaType         = 0	; NdisMedium802_3
*PhysicalMediaType = 19	; NdisPhysicalMediumOther

[XenNet_Reg]
HKR, Ndi, Service, 0, "XenNet"
HKR, Ndi\Interfaces, UpperRange, 0, "ndis5"
HKR, Ndi\Interfaces, LowerRange, 0, "ethernet"

[XenNet_Params_Common]
HKR, Ndi\Params\MTU, ParamDesc, , "MTU"
HKR, Ndi\Params\MTU, default, , "1500"
HKR, Ndi\Params\MTU, type, , "dword"
HKR, Ndi\Params\MTU, min, , "1500"
HKR, Ndi\Params\MTU, max, , "9000"
HKR, Ndi\Params\MTU, step, , "500"
HKR, Ndi\Params\MTU, base, , "10"

HKR, Ndi\Params\ChecksumOffload, ParamDesc, , "Checksum Offload"
HKR, Ndi\Params\ChecksumOffload, default, , "1"
HKR, Ndi\Params\ChecksumOffload, type, , "enum"
HKR, Ndi\Params\ChecksumOffload\enum, 0, , "Disabled"
HKR, Ndi\Params\ChecksumOffload\enum, 1, , "Enabled"

HKR, Ndi\Params\LargeSendOffload, ParamDesc, , "Large Send Offload"
HKR, Ndi\Params\LargeSendOffload, default, , "61440"
HKR, Ndi\Params\LargeSendOffload, type, , "enum"
HKR, Ndi\Params\LargeSendOffload\enum, 0, , "Disabled"
HKR, Ndi\Params\LargeSendOffload\enum, 8192, , "8192"
HKR, Ndi\Params\LargeSendOffload\enum, 16384, , "16384"
HKR, Ndi\Params\LargeSendOffload\enum, 32768, , "32768"
HKR, Ndi\Params\LargeSendOffload\enum, 61440, , "61440"

HKR, Ndi\Params\ScatterGather, ParamDesc, , "Scatter/Gather"
HKR, Ndi\Params\ScatterGather, default, , "1"
HKR, Ndi\Params\ScatterGather, type, , "enum"
HKR, Ndi\Params\ScatterGather\enum, 0, , "Disabled"
HKR, Ndi\Params\ScatterGather\enum, 1, , "Enabled"

HKR, Ndi\Params\RxCoalesce, ParamDesc, , "Rx Coalesce"
HKR, Ndi\Params\RxCoalesce, default, , "1"
HKR, Ndi\Params\RxCoalesce, type, , "enum"
HKR, Ndi\Params\RxCoalesce\enum, 0, , "Disabled"
HKR, Ndi\Params\RxCoalesce\enum, 1, , "Enabled"

HKR, Ndi\Params\NetworkAddress, ParamDesc, , "Locally Administered Address"
HKR, Ndi\Params\NetworkAddress, Type, , "edit"
HKR, Ndi\Params\NetworkAddress, LimitText, , "12"
HKR, Ndi\Params\NetworkAddress, UpperCase, , "1"
HKR, Ndi\Params\NetworkAddress, Default, , ""
HKR, Ndi\Params\NetworkAddress, Optional, , "1"

[XenNet_Params_NDIS5]
HKR, Ndi\Params\ChecksumOffloadRxCheck, ParamDesc, , "Check checksum on RX packets"
HKR, Ndi\Params\ChecksumOffloadRxCheck, default, , "1"
HKR, Ndi\Params\ChecksumOffloadRxCheck, type, , "enum"
HKR, Ndi\Params\ChecksumOffloadRxCheck\enum, 0, , "Disabled"
HKR, Ndi\Params\ChecksumOffloadRxCheck\enum, 1, , "Enabled"

HKR, Ndi\Params\ChecksumOffloadDontFix, ParamDesc, , "Dont fix the blank checksum on offloaded RX packets"
HKR, Ndi\Params\ChecksumOffloadDontFix, default, , "0"
HKR, Ndi\Params\ChecksumOffloadDontFix, type, , "enum"
HKR, Ndi\Params\ChecksumOffloadDontFix\enum, 0, , "Disabled"
HKR, Ndi\Params\ChecksumOffloadDontFix\enum, 1, , "Enabled"

[XenNet_Params_NDIS6]
HKR, Ndi\Params\LargeSendOffloadRxSplitMTU, ParamDesc, , "Allow received packets larger than MTU"
HKR, Ndi\Params\LargeSendOffloadRxSplitMTU, default, , "1"
HKR, Ndi\Params\LargeSendOffloadRxSplitMTU, type, , "enum"
HKR, Ndi\Params\LargeSendOffloadRxSplitMTU\enum, 0, , "Disabled (Limit to MSS)"
HKR, Ndi\Params\LargeSendOffloadRxSplitMTU\enum, 1, , "Half (Split packet in half)"
HKR, Ndi\Params\LargeSendOffloadRxSplitMTU\enum, 2, , "Enabled (Full packet)"

;HKR, Ndi\Params\RxInterruptModeration, ParamDesc, , "Rx Interrupt Moderation (beta)"
;HKR, Ndi\Params\RxInterruptModeration, default, , "0"
;HKR, Ndi\Params\RxInterruptModeration, type, , "enum"
;HKR, Ndi\Params\RxInterruptModeration\enum, 0, , "Disabled"
;HKR, Ndi\Params\RxInterruptModeration\enum, 1, , "Enabled"

[XenNet.CopyFiles]
xennet.sys,,0x00001000 ; COPYFLG_REPLACE_BOOT_FILE

[SourceDisksFiles]
xennet.sys=1

[SourceDisksNames]
1 = %DISK_NAME%

[XenNet_Inst_NDIS5.Services]
AddService=XenNet,2,XenNet_Service 

[XenNet_Inst_NDIS6.Services]
AddService=XenNet,2,XenNet_Service 

[XenNet_Service]
DisplayName    = %XenNet.SVCDESC%                            
ServiceType    = 1
StartType      = 3
ErrorControl   = 1
LoadOrderGroup = NDIS
ServiceBinary  = %12%\xennet.sys                            
AddReg = XenNet_Service_AddReg

[XenNet_Service_AddReg]
; 5 = PciBus, 0 = Internal, 15 = PnpBus
HKR,"Parameters\PnpInterface", "15", 0x00010001, 0x00000001
; hide Qemu Network in XenPCI
HKLM,"SYSTEM\CurrentControlSet\Services\XenPCI\Parameters", "hide_devices", 0x00010008, "#vif#"
HKLM,"SYSTEM\CurrentControlSet\Services\XenPCI\Parameters", "hide_devices", 0x00010008, "VEN_10EC&DEV_8139"
; tell Qemu to hide stuff
HKLM,"SYSTEM\CurrentControlSet\Services\XenPCI\Parameters", "qemu_hide_flags", 0x00010008, %QEMU_UNPLUG_ALL_NICS%

[Strings]
XenGplPv = "Xen GPL PV Driver Developers"
XenNet.SVCDESC = "Xen Net Device Driver"
XenNet.DRVDESC = "Xen Net Device Driver"
DISK_NAME = "Xen Net Device Driver Install Disk"
QEMU_UNPLUG_ALL_IDE_DISKS = 1
QEMU_UNPLUG_ALL_NICS      = 2
QEMU_UNPLUG_AUX_IDE_DISKS = 4
