; Copyright (c) Realtek Semiconductor Corp. All rights reserved.

[Version]
Signature="$Windows NT$"
Class=MTD
ClassGuid = {4d36e970-e325-11ce-bfc1-08002be10318}
Provider=%RTS%
CatalogFile = RtsPer64.cat
DriverVer=08/04/2016,10.0.14393.21292

[SourceDisksFiles]
RtsPer.sys = 99
RsCRIcon.dll = 99
RtCRX64.dll = 99
SDRTCPRM.dll = 99
RtCRU64.exe = 99

[SourceDisksNames.x86]
99 = %DiskDesc%

[SourceDisksNames.amd64]
99 = %DiskDesc%

[SourceDisksNames.ia64]
99 = %DiskDesc%

[DestinationDirs]
CopyFilesSYS = 12     ; should it be 10 to take care of 98 stuff
CopyFilesDLL = 11     ; %SystemRoot%\system or system32 - 98 or Win2000
CopyFilesDLL64 = 10,SysWOW64
CopyCoInstallerDLL64 = 11
CopyFilesCprmDLL = 10,SysWOW64\sda
CopyUninstallAP64 = 10

[Manufacturer]
%VENDOR%=Vendor, NTamd64

[Vendor.NTamd64]
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&CC_FF00
%Rts5227CR%=RTS522A.Inst, PCI\VEN_10EC&DEV_522A&CC_FF00
%Rts5227CR%=RTS5249.Inst, PCI\VEN_10EC&DEV_5249&CC_FF00
%Rts5227CR%=RTS524A.Inst, PCI\VEN_10EC&DEV_524A&CC_FF00
%Rts5227CR%=RTS5250.Inst, PCI\VEN_10EC&DEV_5250
%Rts5227CR%=RTS525A.Inst, PCI\VEN_10EC&DEV_525A&CC_FF00
%Rts5227CR%=RTL8411B.Inst, PCI\VEN_10EC&DEV_5287&CC_FF00
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_604517AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606517AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606617AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606717AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606817AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606A17AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606B17AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_606C17AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_607317AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_608317AA
%Rts5227CR%=RTS5227.Inst, PCI\VEN_10EC&DEV_5227&SUBSYS_608417AA
%Rts5227CR%=RTS522A.Inst, PCI\VEN_10EC&DEV_522A&SUBSYS_608717AA
%Rts5227CR%=RTS522A.Inst, PCI\VEN_10EC&DEV_522A&SUBSYS_609617AA
%Rts5227CR%=RTS522A.Inst, PCI\VEN_10EC&DEV_522A&SUBSYS_609F17AA
%Rts5227CR%=RTS522A.Inst, PCI\VEN_10EC&DEV_522A&SUBSYS_60A017AA
%Rts5227CR%=RTS5249.Inst, PCI\VEN_10EC&DEV_5249&SUBSYS_604517AA
%Rts5227CR%=RTS5249.Inst, PCI\VEN_10EC&DEV_5249&SUBSYS_606117AA
%Rts5227CR%=RTS5249.Inst, PCI\VEN_10EC&DEV_5249&SUBSYS_607617AA
%Rts5227CR%=RTS524A.Inst, PCI\VEN_10EC&DEV_524A&SUBSYS_609817AA
%Rts5227CR%=RTS524A.Inst, PCI\VEN_10EC&DEV_524A&SUBSYS_609B17AA
%Rts5227CR%=RTS524A.Inst, PCI\VEN_10EC&DEV_524A&SUBSYS_60AD17AA
%Rts5227CR%=RTS5250.Inst, PCI\VEN_10EC&DEV_5250&SUBSYS_607317AA
%Rts5227CR%=RTS5250.Inst, PCI\VEN_10EC&DEV_5250&SUBSYS_607B17AA
%Rts5227CR%=RTS525A.Inst, PCI\VEN_10EC&DEV_525A&SUBSYS_608717AA
%Rts5227CR%=RTS525A.Inst, PCI\VEN_10EC&DEV_525A&SUBSYS_608F17AA
%Rts5227CR%=RTS525A.Inst, PCI\VEN_10EC&DEV_525A&SUBSYS_60A017AA
%Rts5227CR%=RTS525A.Inst, PCI\VEN_10EC&DEV_525A&SUBSYS_60A917AA

[Rts.NTia64.CoInstallers_AddReg]
HKR,,CoInstallers32,0x00010000,"RtCRX64.dll,RtCR_CoInstaller"

[Rts.ntamd64.CoInstallers_AddReg]
HKR,,CoInstallers32,0x00010000,"RtCRX64.dll,RtCR_CoInstaller"

[Rts.Uninstall_AddReg]
HKLM,%RTSCR_UNINSTALL%,DisplayName,,"Realtek Card Reader"
HKLM,%RTSCR_UNINSTALL%,UninstallString,,%10%"\RtCRU64.exe /u"
HKLM,%RTSCR_UNINSTALL%,DisplayIcon,,%10%"\RtCRU64.exe"
HKLM,%RTSCR_UNINSTALL%,Publisher,,%VENDOR%
HKLM,%RTSCR_UNINSTALL%,DisplayVersion,,%DriverVersion%
HKLM,%RTSCR_UNINSTALL%,EstimatedSize,0x00010001,15000

[MsiEnable_addreg]
;HKR, "Interrupt Management\MessageSignaledInterruptProperties", MessageNumberLimit, 0x00010001, 1
HKR, "Interrupt Management",,0x00000010
HKR, "Interrupt Management\MessageSignaledInterruptProperties",,0x00000010
HKR, "Interrupt Management\MessageSignaledInterruptProperties", "MSISupported", 0x00010001, 1
HKR, "e5b3b5ac-9725-4f78-963f-03dfb1d828c7", "D3ColdSupported", 0x00010001, 1

[CopyFilesSYS]
RtsPer.sys

[CopyFilesDLL]
RsCRIcon.dll

[CopyFilesDLL64]
RsCRIcon.dll

[CopyCoInstallerDLL64]
RtCRX64.dll

[CopyFilesCprmDLL]
SDRTCPRM.dll

[CopyUninstallAP64]
RtCRU64.exe

[DefaultInstall.NTx86]
CopyFiles = CopyFilesSYS, CopyFilesDLL

[DefaultInstall.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesDLL64, CopyCoInstallerDLL64, CopyFilesCprmDLL, CopyUninstallAP64

[DefaultInstall.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesDLL64, CopyCoInstallerDLL64, CopyFilesCprmDLL, CopyUninstallAP64

[DefaultInstall.Services]
AddService = RTSPER, 0x00000002, DefaultInstall_Service_Inst

[DefaultInstall_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = DefaultInstall.AddReg, Rts.Uninstall_AddReg

[DefaultInstall.AddReg]

[RTS5227.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTS5227.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS5227.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTS5227.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS5227.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTS5227.Inst.NTx86.HW]
AddReg=MsiEnable_addreg

[RTS5227.Inst.NTamd64.HW]
AddReg=MsiEnable_addreg

[RTS5227.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTS5227_Service_Inst

[RTS5227.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTS5227_Service_Inst

[RTS5227.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTS5227_Service_Inst

[RTS5227_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTS5227.AddReg, Rts.Uninstall_AddReg

[RTS5227.AddReg]
HKR,"RTS5227","MSIEnable",0x10001,1
HKR,"RTS5227","FirstLoad",0x10001,1
HKR,"RTS5227","NonRemovable",0x10001,1

[RTS5249.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTS5249.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS5249.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTS5249.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS5249.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTS5249.Inst.NTx86.HW]
AddReg=MsiEnable_addreg

[RTS5249.Inst.NTamd64.HW]
AddReg=MsiEnable_addreg

[RTS5249.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTS5249_Service_Inst

[RTS5249.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTS5249_Service_Inst

[RTS5249.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTS5249_Service_Inst

[RTS5249_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTS5249.AddReg, Rts.Uninstall_AddReg

[RTS5249.AddReg]
HKR,"RTS5249","MSIEnable",0x10001,1
HKR,"RTS5249","FirstLoad",0x10001,1
HKR,"RTS5249","NonRemovable",0x10001,1

[RTS5250.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTS5250.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS5250.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTS5250.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS5250.Inst.NTx86.HW]    	;MSI
AddReg=MsiEnable_addreg

[RTS5250.Inst.NTamd64.HW]    	;MSI
AddReg=MsiEnable_addreg

[RTS5250.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTS5250.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTS5250_Service_Inst

[RTS5250.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTS5250_Service_Inst

[RTS5250.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTS5250_Service_Inst

[RTS5250_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTS5250.AddReg, Rts.Uninstall_AddReg

[RTS5250.AddReg]
HKR,"RTS5250","MSIEnable",0x10001,1
HKR,"RTS5250","FirstLoad",0x10001,1
HKR,"RTS5250","NonRemovable",0x10001,1

[RTL8411B.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTL8411B.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTL8411B.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTL8411B.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTL8411B.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTL8411B.Inst.NTx86.HW]
AddReg=MsiEnable_addreg

[RTL8411B.Inst.NTamd64.HW]
AddReg=MsiEnable_addreg

[RTL8411B.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTL8411B_Service_Inst

[RTL8411B.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTL8411B_Service_Inst

[RTL8411B.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTL8411B_Service_Inst

[RTL8411B_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTL8411B.AddReg, Rts.Uninstall_AddReg

[RTL8411B.AddReg]
HKR,"RTL8411B","MSIEnable",0x10001,1
HKR,"RTL8411B","FirstLoad",0x10001,1
HKR,"RTL8411B","NonRemovable",0x10001,1

[RTS522A.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTS522A.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS522A.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTS522A.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS522A.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTS522A.Inst.NTx86.HW]
AddReg=MsiEnable_addreg

[RTS522A.Inst.NTamd64.HW]
AddReg=MsiEnable_addreg

[RTS522A.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTS522A_Service_Inst

[RTS522A.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTS522A_Service_Inst

[RTS522A.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTS522A_Service_Inst

[RTS522A_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTS522A.AddReg, Rts.Uninstall_AddReg

[RTS522A.AddReg]
HKR,"RTS522A","MSIEnable",0x10001,1
HKR,"RTS522A","FirstLoad",0x10001,1
HKR,"RTS522A","NonRemovable",0x10001,1

[RTS524A.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTS524A.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS524A.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTS524A.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS524A.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTS524A.Inst.NTx86.HW]
AddReg=MsiEnable_addreg

[RTS524A.Inst.NTamd64.HW]
AddReg=MsiEnable_addreg

[RTS524A.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTS524A_Service_Inst

[RTS524A.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTS524A_Service_Inst

[RTS524A.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTS524A_Service_Inst

[RTS524A_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTS524A.AddReg, Rts.Uninstall_AddReg

[RTS524A.AddReg]
HKR,"RTS524A","MSIEnable",0x10001,1
HKR,"RTS524A","FirstLoad",0x10001,1
HKR,"RTS524A","NonRemovable",0x10001,1

[RTS525A.Inst.NTx86]
CopyFiles = CopyFilesSYS

[RTS525A.Inst.NTia64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS525A.Inst.NTia64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.NTia64.CoInstallers_AddReg

[RTS525A.Inst.ntamd64]
CopyFiles = CopyFilesSYS, CopyFilesCprmDLL, CopyUninstallAP64

[RTS525A.Inst.ntamd64.CoInstallers]
CopyFiles=CopyFilesDLL64, CopyCoInstallerDLL64
AddReg=Rts.ntamd64.CoInstallers_AddReg

[RTS525A.Inst.NTx86.HW]
AddReg=MsiEnable_addreg

[RTS525A.Inst.NTamd64.HW]
AddReg=MsiEnable_addreg

[RTS525A.Inst.NTx86.Services]
AddService = RTSPER, 0x00000002, RTS525A_Service_Inst

[RTS525A.Inst.NTia64.Services]
AddService = RTSPER, 0x00000002, RTS525A_Service_Inst

[RTS525A.Inst.ntamd64.Services]
AddService = RTSPER, 0x00000002, RTS525A_Service_Inst

[RTS525A_Service_Inst]
DisplayName    = %Rts5227PER%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_IGNORE%
ServiceBinary  = %12%\RtsPer.sys
AddReg         = RTS525A.AddReg, Rts.Uninstall_AddReg

[RTS525A.AddReg]
HKR,"RTS525A","MSIEnable",0x10001,1
HKR,"RTS525A","FirstLoad",0x10001,1
HKR,"RTS525A","NonRemovable",0x10001,1

[Strings]
;Localizable Strings needed for HBA naming in Windows UI
;*******************************************
;Non-Localizable strings
RTS = "Realtek Semiconductor Corp."
VENDOR         = "Realtek Semiconductor Corp."
Rts5227CR      = "Realtek PCIE CardReader"
Rts5227PER      = "Realtek PCIE Card Reader - PER"
DiskDesc = "Realtek PCIE Card Reader Source Disk"
RTSCR_UNINSTALL="Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\{5BC2B5AB-80DE-4E83-B8CF-426902051D0A}"
DriverVersion = "10.0.14393.21292"
SERVICE_ASSOCSERVICE = 0x00000002
SERVICE_BOOT_START     = 0x0
SERVICE_SYSTEM_START   = 0x1
SERVICE_AUTO_START     = 0x2
SERVICE_DEMAND_START   = 0x3
SERVICE_DISABLED       = 0x4
SERVICE_KERNEL_DRIVER  = 0x1
SERVICE_ERROR_IGNORE   = 0x0
SERVICE_ERROR_NORMAL   = 0x1
SERVICE_ERROR_SEVERE   = 0x2
SERVICE_ERROR_CRITICAL = 0x3
REG_EXPAND_SZ          = 0x00020000
REG_DWORD              = 0x00010001
REG_MULTI_SZ           = 0x00010000
REG_BINARY             = 0x00000001
REG_SZ                 = 0x00000000

