;---------------------------------------------------------------------------- ; ; Filename: OEMSETUP.INF ; Version: 3.6 ; Product: IBM Token-Ring PCI Family Adapters ; ; Copyright: (C) 1996-1999 IBM Corporation. All rights reserved. ; ; Description: ; ; NIC Installation Script for Windows NT 4.0 ; ; ; Change log: ; ; 3.6 mpl - fix for install of cardbus adapter when GetPCIInformation fails ; - detect presence of softex/cardwizard ; - integrate softex changes for common INF (softex/non-softex) ; ; 3.5 mpl - add support for Softex ; - change "adapter not found" message to include possibility ; of no point enabler ; ; 3.4 mpl - add support for CardBus adapter ; - store FeatureMask in registry ; ; 3.3 sgp - NetworkAddress obsoletes NetAddrees as the LAA parameter ; - SMP_Mode now obsolete ; ; 3.2 sgp - SVID/SID support added to INF and DLL detection routines ; ; 3.1 sgp - Better migration from device drivers version <= 5.12. ; INF deletes the control panel applet installed by 5.11 (if ; it exists) and also converts old RNIC config to new RNIC ; config. ; ; 3.0 sgp - Support for new DLL interface (ITR_*) added ; - Support for Windows NT 3.51 / NDIS 3.1 driver removed ; ;---------------------------------------------------------------------------- [Identification] OptionType = NetAdapter [PlatformsSupported] PCI [LanguagesSupported] ENG [Options] TRP [OptionsTextENG] TRP = "IBM Token-Ring PCI Family Adapter" [GeneralConstants] from = "" to = "" KeyNull = "" AdapterList = {} MAXIMUM_ALLOWED = 33554432 RegistryErrorIndex = NO_ERROR KeyProduct = "" TRUE = 1 FALSE = 0 NoTitle = 0 OldVersionExisted = $(FALSE) SSoftCB = $(FALSE) SoftexCB = $(FALSE) RiggedCB = $(FALSE) [FileConstants] ; These should be left alone. UtilityInf = "UTILITY.INF" ParamInf = "NCPARAM.INF" SubroutineInf = "SUBROUTN.INF" SoftwareType = "driver" NetRuleSoftwareUse = $(SoftwareType) ; Event logging message files NetEventDLL = "%SystemRoot%\System32\NETEVENT.DLL;%SystemRoot%\System32\IBMSGNET.DLL" ; These constants vary depending on Software, Manufacturer, etc. Manufacturer = "IBM" ProductMajorVersion = "3" ProductMinorVersion = "0" ProductVersion = $(ProductMajorVersion)"."$(ProductMinorVersion) ; Dialog box parameters InstallDLL = $(!STF_WINDOWSSYSPATH)"\ITR_W32.Dll" ; PnP Information IBM_VENDOR_ID = 4116 ; 0x1014 in decimal PIT_DEVICE_ID = 62 ; 0x003E in decimal PIT_ADAPTER_ID = 269746238 ; 0x1014003E in decimal ; Hardware binding information. ProductHardwareName = "IBMTRP" NetRuleHardwareType = "IBMTRP IBMTRPAdapter" NetRuleHardwareBindForm = " yes yes container" NetRuleHardwareClass = {"IBMTRPAdapter basic"} ; Software binding information. ProductSoftwareName = "IBMTRP" NetRuleSoftwareType = "IBMTRPSys ndisDriver IBMTRPDriver" NetRuleSoftwareBindForm = """IBMTRPSys"" yes no container" NetRuleSoftwareClass = {"IBMTRP basic"} NetRuleSoftwareBindable = {"IBMTRPDriver IBMTRPAdapter non exclusive 100"} ProductSoftwareImagePath = "System32\drivers\IBMTRP.SYS" DriverFile = "IBMTRP.SYS" ; Various places in the registry we use ProductKeyName = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion" ParamKeyName = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters" NetworkCardKeyName = $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards" NetworkDriverKeyName = $(!NTN_ServiceBase)"\"$(ProductHardwareName) SystemSoftKey = $(!NTN_SoftwareBase)"\SystemSoft\CardWizard for Windows NT" SoftexKey = $(!NTN_SoftwareBase)"\Softex Inc.\pcmapp" ; We used to keep our ProductKeyName in the Microsoft sub-tree... oops. ; This is used in both RemoveAdapter and UpgradeSoftware portion of the INF. OldProductKeyName = $(!NTN_SoftwareBase)"\Microsoft\"$(ProductSoftwareName)"\CurrentVersion" OldManufacturer = "Microsoft" ; NDIS Level Strings (default is NDIS4_Level; changed later if Windows NT 3.5x detected) NDIS4_Level = "NDIS 4.0" NDIS3_Level = "NDIS 3.1" NDIS_Level = $(NDIS4_Level) ; Uncomment the appropriate lines below if you want to install ; a certain NDIS level driver REGARDLESS of the INF's detection ; of the Operating System. This can be useful if you want to ; mandate use of the NDIS 3.1 miniport. ForceNDIS = "NO" ; the default, comment out if forcing ; ForceNDIS = $(NDIS3_Level) ; force use of NDIS 3.1 ; ForceNDIS = $(NDIS4_Level) ; force use of NDIS 4.0 ; No CSD applied string NO_CSD = "NO_CSD" ; Driver location after installation ; No secondary adapter RNIC_Not = "0" [FileConstantsENG] ; Contains localized strings for the appropriate version of the adapter. FunctionTitle = "IBM Token Ring PCI Family NIC Miniport Setup" ProductSoftwareDescription = "IBM Token-Ring PCI Family Adapter Miniport" ProductHardwareDescription = "IBM Token-Ring PCI Family Adapter" ProductSoftwareTitle = "IBM Token-Ring PCI Family Adapter Miniport" ProductHardwareTitle = "IBM Token-Ring PCI Family Adapter " ; Leave in trailing space CANNOT_FIND_ANY_CARD = "An adapter of this type is not present in the system. If you get this message after attempting to install a CardBus adapter, please ensure that a compatible 3rd party card/socket services software package is installed on your computer before attempting to install the network adapter. Consult the documentation that came with your network adapter for more details." ShellCodeErrorTitle = "Error: "$(FunctionTitle) ShellCodeErrorText = "OEMSETUP.INF Shell Code Error!" DiskName = "Token Ring PCI Device Drivers: Windows 95/98/NT (CD-ROM or diskette)" TRP_TITLE = "IBM Token-Ring PCI Family Adapter" ; These lines are to fix a bug in gauge.c line 209 in WinNT 4.x checked build. ProCaption = "Windows NT Setup" ProCancel = "Cancel" ProCancelMsg = "Windows NT Networking is not correctly installed. "+ "Are you sure you want to cancel copying files?" ProCancelCap = "Network Setup Message" ProText1 = "Copying:" ProText2 = "To:" [ProductType] STF_PRODUCT = Winnt STF_PLATFORM = I386 [date] Now = {} ? $(!LIBHANDLE) GetSystemDate ;------------------------------------------------------------------- ; SECTION NAME: Identify ; ; DESCRIPTION: This required section verifies that this ; script supports the option currently selected. ; ; INPUT: None. ; ; OUTPUT: $($R0) Status ; $($R1) Option Type ; $($R2) Diskette Description ;------------------------------------------------------------------- [Identify] read-syms Identification set Status = STATUS_SUCCESSFUL set Identifier = $(OptionType) set Media = #("Source Media Descriptions", 1, 1) return $(Status) $(OptionType) $(Media) ;------------------------------------------------------------------- ; SECTION NAME: ReturnOptions ; ; DESCRIPTION: This required section returns the list of ; options supported by this script and the ; text list representing the options. ; ; ; INPUT: $($0) Language code ; ; OUTPUT: $($R0) Status ; $($R1) Option List ; $($R2) Option Text List ;------------------------------------------------------------------- [ReturnOptions] set Status = STATUS_FAILED set OptionList = {} set OptionTextList = {} set LanguageList = ^(LanguagesSupported, 1) ifcontains(i) $($0) not-in $(LanguageList) set Status = STATUS_NOLANGUAGE goto End_ReturnOptions endif ifstr(i) $($1) == "" goto OK_ReturnOptions endif set PlatformList = ^(PlatformsSupported, 1) Ifcontains(i) $($1) in $(PlatformList) goto OK_ReturnOptions else set Status = STATUS_NOTSUPPORTED goto End_ReturnOptions endif OK_ReturnOptions = + set OptionList = ^(Options, 1) set OptionTextList = ^(OptionsText$($0), 1) ; ** Hack for upgrading older IBMTRP full MAC driver --sgp ifstr(i) $(!NTN_InstallMode) == Update Set OptionList = {"IBMTRP", "TRP" } endif set Status = STATUS_SUCCESSFUL End_ReturnOptions = + Return $(Status) $(OptionList) $(OptionTextList) ;----------------------------------------------------------------- ; ; SECTION NAME: Source Media Description ; ; DESCRIPTION: This is a required DETECT section ; ;------------------------------------------------------------------ [Source Media Descriptions] 1 = $(DiskName) ;------------------------------------------------------------------- ; SECTION NAME: InstallOption ; ; DESCRIPTION: Main entry point. Shelled to by main ; installation processing or by NCPASHEL.INF ; during reconfiguration, removal, update, ; etc. It performs three main functions: ; ; 1. Copies files representing options ; 2. Configures the installed option ; 3. Updates the registry for the installed ; option. ; ; INPUT: $($0) Language to use ; $($1) OptionID to install ; $($2) SourceDirectory ; $($3) AddCopy (YES | NO) ; $($4) DoCopy (YES | NO) ; $($5) DoConfig (YES | NO) ; ; OUTPUT: $($R0) Status ; ;------------------------------------------------------------------- [InstallOption] ; Uncomment the line below to enable debugging ; set !G:DebugOutputControl = 1 StartWait set Status = STATUS_FAILED set Option = $($1) set SrcDir = $($2) set AddCopy = $($3) set DoCopy = $($4) set DoConfig = $($5) set LanguageList = ^(LanguagesSupported, 1) Ifcontains(i) $($0) NOT-IN $(LanguageList) Return STATUS_NOLANGUAGE endif read-syms GeneralConstants read-syms FileConstants read-syms FileConstants$(!STF_LANGUAGE) read-syms OptionsText$(!STF_LANGUAGE) detect date set-title $(FunctionTitle) ; This code detects the Windows NT Version from the registry set CurrentVersionValue = "" set CurrentCSDVersionValue = {} Debug-Output "Getting version information from registry..." OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion" $(!REG_KEY_READ) KeyWinNT ifstr(i) $(KeyWinNT) != "" GetRegValue $(KeyWinNT) "CurrentVersion" CurrentVersionValue set m_WinNTVersion = *($(CurrentVersionValue),4) Debug-Output "** Current Windows NT Version is "$(m_WinNTVersion) ifstr(i) $(m_WinNTVersion) == "4.0" GetRegValue $(KeyWinNT) "CSDVersion" CurrentCSDVersionValue ifstr(i) *($(CurrentCSDVersionValue),4) == "" ; Key doesn't exist, so no Service Pack applied! set m_CSDVersion = $(NO_CSD) Debug-Output "** Running NT 4.0: No service pack applied!" else set m_CSDVersion = *($(CurrentCSDVersionValue),4) Debug-Output "** Running NT 4.0: Current Service Pack Level is "$(m_CSDVersion) endif endif CloseRegKey $(KeyWinNT) else Debug-Output "No version information availiable." endif ; Set the version information up for the proper version (NDIS3/NDIS4) ; we are installing. The default is to use the NDIS4 version. set NDIS_Level = $(NDIS4_Level) ifstr(i) $(m_WinNTVersion) == "3.51" ; Using WinNT 3.51 and NDIS 3.1 miniport! ; set NDIS_Level = $(NDIS3_Level) ;else-ifstr(i) $(m_WinNTVersion) == "3.50" ; Uh-oh... NT 3.50... abort! ;set Error = "This driver release only supports Microsoft Windows NT versions 3.51 and 4.0." set Error = "This driver release only supports Microsoft Windows NT version 4.0, Windows 95 OSR2.x (4.00.950 B or later), Windows 98, and Windows 2000. Please download the driver for Microsoft Windows NT 3.51 from the support website." set to = end set from = end goto nonfatal endif Debug-Output "Current Product Version we're installing is "$(ProductVersion) ; On older INFs, we used "Microsoft" for the manufacturer. ; Newer installs such as this one uses "IBM" (correctly!). ; This code detects where our software is located in the ; HKEY_LOCAL_MACHINE\Software tree so that the upgrade ; and removal functions work properly. set KeyProduct = "" set CurrentManufacturer = "" set CurrentProductKeyName = "" OpenRegKey $(!REG_H_LOCAL) "" $(OldProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct Ifstr(i) $(KeyProduct) != $(KeyNull) Debug-Output "Fixing setup for wrong manufacturer." set CurrentManufacturer = $(OldManufacturer) set CurrentProductKeyName = $(OldProductKeyName) CloseRegKey $(KeyProduct) else set CurrentManufacturer = $(Manufacturer) set CurrentProductKeyName = $(ProductKeyName) endif ; The old Full MAC version of this driver used the option "IBMTRP". ; Correct it here so that, once we upgrade the component, it will still ; work. ifstr(i) $(Option) == "IBMTRP" set Option = "TRP" endif ; Code to correct some unattended installations that don't set ; SrcDir correctly... ifstr(i) $(!STF_GUI_UNATTENDED) == "YES" Debug-Output "Doing unattended installation..." ifstr(i) $(!OEMNetOption) == "YES" ifstr(i) $(!OEMNetDrive) != "" Debug-Output "Correcting SrcDir to point to !OEMNetDrive" set SrcDir = $(!OEMNetDrive) endif endif endif ; If ForceNDIS is set, check it fpr a NDIS version. Default to ; use the automatically detected version of NDIS 4.0. ifstr(i) $(ForceNDIS) == $(NDIS3_Level) set NDIS_Level = $(NDIS3_Level) Debug-Output "NDIS 3.1 forced" else-ifstr(i) $(ForceNDIS) == $(NDIS4_Level) Debug-Output "NDIS 4.0 forced" set NDIS_Level = $(NDIS4_Level) else Debug-Output "Using Automatically Detected NDIS Level" endif ; Fixes NetAddress to be NetworkAddress, if it doesn't exist OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) NetCardKey ifstr(i) $(NetCardKey) == "" goto NotInstalledYet endif GetRegValue $(NetCardKey) "ServiceName" ServiceInfo set ServiceName = *($(ServiceInfo),4) CloseRegKey $(NetCardKey) OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(ServiceName)"\Parameters" $(MAXIMUM_ALLOWED) KeyParams ifstr(i) $(KeyParams) != $(KeyNull) GetRegValue $(KeyParams) "NetworkAddress" CurrLAA ifint $(RegLastError) != "0" Debug-Output "We don't have a NetworkAddress parameter." GetRegValue $(KeyParams) "NetAddress" CurrLAA ifint $(RegLastValue) == "0" Debug-Output "We do have a NetAddress parameter." set temp = *($(CurrLAA),4) set NewValueList = {NetworkAddress,0,$(!REG_VT_SZ),$(temp)} Debug-Output $(NewValueList) SetRegValue $(KeyParams) $(NewValueList) Debug-Output "Converted existing NetAddress to NetworkAddress" endif endif CloseRegKey $(KeyParams) endif NotInstalledYet = + set to = Begin set from = Begin set CommonStatus = STATUS_SUCCESSFUL EndWait ; ----------------------------------------------------------------- ; Begin - Determine what option we are being called with ; ----------------------------------------------------------------- Begin = + ifstr(i) $(!NTN_InstallMode) == DeInstall set from = fatal set to = fatal goto RemoveAdapter else-ifstr(i) $(!NTN_InstallMode) == Update set from = fatal set to = fatal goto UpgradeSoftware else-ifstr(i) $(!NTN_InstallMode) == Bind set from = fatal set to = fatal goto BindingAdapter else-ifstr(i) $(!NTN_InstallMode) == Configure set CommonStatus = STATUS_REBOOT Debug-Output "$(ProductKeyName) = "$(CurrentProductKeyName) Debug-Output "$(!NTN_RegBase) = "$(!NTN_RegBase) ifstr(i) $(CurrentProductKeyName) == $(!NTN_RegBase) Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set Error = $($R0) set from = end set to = end Debug-Output "Going to NonFatalInfo" goto NonFatalInfo endif set from = fatal set to = fatal goto ConfigureAdapter else set OEM_ABANDON_OPTIONS = {} set OEM_ABANDON_SOFTWARE = FALSE set OEM_ABANDON_ON = TRUE set from = fatal set to = fatal goto InstallAdapter endif ; ----------------------------------------------------------------- ; InstallAdapter - ; ----------------------------------------------------------------- InstallAdapter = + Debug-Output "Inside InstallAdapter" Debug-Output "ProductKeyName = "$(CurrentProductKeyName) set KeyProduct = "" OpenRegKey $(!REG_H_LOCAL) "" $(CurrentProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct Debug-Output "Just after OpenRegKey" Debug-Output "KeyProduct = "$(KeyProduct) Debug-Output "KeyNull = "$(KeyNull) Ifstr $(KeyProduct) == $(KeyNull) set OldVersionExisted = $(FALSE) goto DetectAndInstall endif ; ----------------------------------------------------------------- ; OldInstall - ; ----------------------------------------------------------------- OldInstall = + CloseRegKey $(KeyProduct) ifstr(i) $(!NTN_RegBase) == $(CurrentProductKeyName) Debug-Output "(!NTN_RegBase)="$(!NTN_RegBase) Debug-Output "(ProductKeyName)="$(CurrentProductKeyName) Debug-Output "(ProductSoftwareTitle)="$(ProductSoftwareTitle) Debug-Output "(ProductVersion)="$(ProductVersion) Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+ $(ProductVersion) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif goto end else Shell $(UtilityInf), CardExistedDlg ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif ifstr(i) $($R1) != "OK" Set CommonStatus = STATUS_USERCANCEL goto end endif set OldVersionExisted = $(TRUE) endif ; ----------------------------------------------------------------- ; DetectAndInstall - Check to see if the adapter exists. If so, ; copy everything needed, and set default ; parameters regardless of whether the install ; is attended or unattended.. ; ----------------------------------------------------------------- DetectAndInstall = + Debug-Output "Detecting any PCI Token Ring adapters..." ; ------------------------------------------------------------ ; Start of PCI logic ; ------------------------------------------------------------ ;first, see if softex or cardwizard is on this machine OpenRegKey $(!REG_H_LOCAL) "" $(SystemSoftKey) $(MAXIMUM_ALLOWED) KeyCBProduct ifstr $(KeyCBProduct) != $(KeyNull) Debug-Output "SystemSoft software installed" set SSoftCB = $(TRUE) CloseRegKey $(KeyCBProduct) endif OpenRegKey $(!REG_H_LOCAL) "" $(SoftexKey) $(MAXIMUM_ALLOWED) KeyCBProduct ifstr $(KeyCBProduct) != $(KeyNull) Debug-Output "Softex software installed" set SoftexCB = $(TRUE) CloseRegKey $(KeyCBProduct) endif set Vendor_ID = $(IBM_VENDOR_ID) set Device_ID = $(PIT_DEVICE_ID) Shell $(UtilityInf), GetPCIInformation, $(Vendor_ID), $(Device_ID) ifint $($ShellCode) != $(!SHELL_CODE_OK) ifstr(i) $(AdapterList) == {} set PCI_List = {{0,-1,0}} endif goto ShellCodeError else set PCI_List = $($R0) endif ifstr(i) $(PCI_List) != {} Debug-Output "PCI_List = "$(PCI_List) ForListDo $(PCI_List) Set BusSlotPCI = $($) Set BusNumber = *($(BusSlotPCI),1) Set SlotNumber = *($(BusSlotPCI),2) Set NetcardId = $(PIT_ADAPTER_ID) Set BusSlotPCI = {$(BusNumber),$(SlotNumber),$(NetcardId)} Set AdapterList = >($(AdapterList),$(BusSlotPCI)) EndForListDo ; End of PCI_List endif Debug-Output "AdapterList ="$(AdapterList) ; ------------------------------------------------------------ ; End of PCI logic ; ------------------------------------------------------------ ifstr(i) $(AdapterList) == {} Debug-Output "Did not find any PCI Token-Ring Adapters" ifstr $(SSoftCB) == $(TRUE) Set AdapterList = {"{""0"",""0"",""269746238""}"} Set BusNumber = 0;*($(BusSlotPCI),1) Set SlotNumber = 0;*($(BusSlotPCI),2) Set NetcardId = $(PIT_ADAPTER_ID) Set BusSlotPCI = {$(BusNumber),$(SlotNumber),$(NetcardId)} set RiggedCB = $(TRUE) else-ifstr $(SoftexCB) == $(TRUE) Set AdapterList = {"{""0"",""0"",""269746238""}"} Set BusNumber = 0;*($(BusSlotPCI),1) Set SlotNumber = 0;*($(BusSlotPCI),2) Set NetcardId = $(PIT_ADAPTER_ID) Set BusSlotPCI = {$(BusNumber),$(SlotNumber),$(NetcardId)} set RiggedCB = $(TRUE) else set Error = $(CANNOT_FIND_ANY_CARD) set CommonStatus = STATUS_USERCANCEL set from = "end" goto nonfatal endif endif ifint $(OldVersionExisted) == $(FALSE) goto NewDriverInstall else goto AfterNewDriverInstall endif NewDriverInstall = + ; ------------------------------------------------------------- ; If new install: Copy the driver, INF, DLL and Help files. ; ------------------------------------------------------------- Debug-Output "Preparing to copy installation files..." Debug-Output "STF_CWDDIR = "$(!STF_CWDDIR) Debug-Output "STF_SRCDIR = "$(!STF_SRCDIR) Install "Install-Option" ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE" ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set Error = $($R0) goto fatal endif Debug-Output "Manufacturer = "$(CurrentManufacturer) Debug-Output "ProductSoftwareName = "$(ProductSoftwareName) Debug-Output "ProductSoftwareTitle = "$(ProductSoftwareTitle) Debug-Output "STF_CONTEXTINFNAME = "$(STF_CONTEXTINFNAME) Debug-Output "ProductSoftwareImagePath = "$(ProductSoftwareImagePath) Debug-Output "NetEventDLL = "$(NetEventDLL) Debug-Output "Finished file copy." Shell $(UtilityInf), AddSoftwareComponent, $(CurrentManufacturer), + $(ProductSoftwareName), + $(ProductSoftwareName), + $(ProductSoftwareTitle), $(STF_CONTEXTINFNAME), + $(ProductSoftwareImagePath), "kernel", "NDIS", {}, "",+ $(NetEventDLL) Set OEM_ABANDON_SOFTWARE = TRUE ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR" EndWait CloseRegKey $($R1) CloseRegKey $($R2) CloseRegKey $($R3) CloseRegKey $($R4) CloseRegKey $($R5) goto FatalRegistry endif Set SoftProductKey = $($R1) Set SoftNetRuleKey = $($R2) Set SoftServiceKey = $($R3) Set SoftParameterKey = $($R4) Set SoftLinkageKey = $($R5) set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+ {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+ {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+ {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitle)},+ {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescription)},+ {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+ {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}} Debug-Output "NewValueList = "$(NewValueList) Debug-Output "SoftProductKey ="$(SoftProductKey) Debug-Output "SoftNetRuleKey ="$(SoftNetRuleKey) Debug-Output "SoftServiceKey ="$(SoftServiceKey) Debug-Output "SoftParameterKey ="$(SoftParameterKey) Debug-Output "SoftLinkageKey ="$(SoftLinkageKey) Shell $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR" EndWait CloseRegKey $(SoftProductKey) CloseRegKey $(SoftNetRuleKey) CloseRegKey $(SoftServiceKey) CloseRegKey $(SoftParameterKey) CloseRegKey $(SoftLinkageKey) goto FatalRegistry endif set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareType)},+ {use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUse)}, + {bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindForm)}, + {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClass)}, + {bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindable)}, + {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}} Debug-Output "NewValueList = "$(NewValueList) Shell $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) CloseRegKey $(SoftProductKey) CloseRegKey $(SoftNetRuleKey) CloseRegKey $(SoftServiceKey) CloseRegKey $(SoftParameterKey) CloseRegKey $(SoftLinkageKey) Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR" EndWait goto FatalRegistry endif AfterNewDriverInstall = + ; ; Loop through the Adapter List and install as many instances of the Token ; Ring Adapter that we have. ; ; We'll be needing this for SVID/SID detection LoadLibrary "X" $(InstallDLL) hDLL ForListDo $(AdapterList) Set BusSlotPci = $($) Set BusNumber = *($(BusSlotPci),1) Set SlotNumber = *($(BusSlotPci),2) Set NetcardId = *($(BusSlotPci),3) ; ------------------------------------------------- ; If netcard is already installed, skip this entry ; ------------------------------------------------- Debug-Output "BusSlotPci = "$(BusSlotPci) Debug-Output "BusNumber = "$(BusNumber) Debug-Output "SlotNumber = "$(SlotNumber) Debug-Output "NetcardId = "$(NetcardId) Set AlreadyInstalled = "NO" ; Make a list of all the installed netcards ; OpenRegKey gets a handle to a Key OpenRegKey + $(!REG_H_LOCAL),+ "",+ $(NetworkCardKeyName),+ $(MAXIMUM_ALLOWED),+ IE_KeyNetcards Ifstr $(IE_KeyNetcards) == $(KeyNull) set RegistryErrorIndex = UNABLE_OPEN_NETWORKCARD_SECTION goto FatalRegistry endif EnumRegKey $(IE_KeyNetcards) IE_KeyNameList ; Compare all the NetworkCards entries to see whether ; they match the current bus number, slot number, title, ; and product name. Debug-Output "IE_KeyNameList ="$(IE_KeyNameList) ForListDo $(IE_KeyNameList) set IE_KeyName = *($($),1) OpenRegKey + $(IE_KeyNetcards),+ "",+ $(IE_KeyName),+ $(MAXIMUM_ALLOWED),+ IE_Card Debug-Output "IE_Card = "$(IE_Card) Ifstr $(IE_Card) == $(KeyNull) set RegistryErrorIndex = UNABLE_OPEN_NETWORKCARD_SECTION goto FatalRegistry endif GetRegValue $(IE_Card),"Description", DescriptionInfo GetRegValue $(IE_Card),"ProductName", ProductNameInfo set CardDescription = *($(DescriptionInfo), 4) set CardProductName = *($(ProductNameInfo), 4) Debug-Output "CardDescription = "$(CardDescription) Debug-Output "ProductHardwareDescription = "$(ProductHardwareDescription) Debug-Output "CardProductName = "$(CardProductName) Debug-Output "ProductHardwareName = "$(ProductHardwareName) ifstr(i) $(CardProductName) == $(ProductHardwareName) ; The product type matches. Now check for a ; match on bus number and slot number. GetRegValue $(IE_Card), "ServiceName", ServiceNameInfo Set ServiceName = *($(ServiceNameInfo), 4) Debug-Output "ServiceName ="$(ServiceName) OpenRegKey + $(!REG_H_LOCAL),+ "",+ "SYSTEM\CurrentControlSet\Services\"$(ServiceName)"\Parameters",+ $(MAXIMUM_ALLOWED),+ IE_KeyService Ifstr $(IE_KeyService) == $(KeyNull) set RegistryErrorIndex = UNABLE_OPEN_NETWORKCARD_SECTION goto FatalRegistry endif ; We are now in the parameters key for the adapter ; to which we are comparing the current adapter GetRegValue $(IE_KeyService), "BusNumber", BusInfo set CardBusNum = *($(BusInfo), 4) GetRegValue $(IE_KeyService), "SlotNumber", SlotInfo set CardSlotNum = *($(SlotInfo), 4) Debug-Output "CardBusNum ="$(CardBusNum) Debug-Output "BusNumber ="$(BusNumber) ifint $(CardBusNum) == $(BusNumber) ifint $(CardSlotNum) == $(SlotNumber) Set AlreadyInstalled = "YES" endif endif endif EndForListDo ifstr(i) $(AlreadyInstalled) == "YES" goto NextAdapter endif ; ------------------------------------------------- ; The netcard has not yet been installed. Add ; it now. ; ------------------------------------------------- ; Determine the CardId parameter first, as well as the ProductHardwareTitle. ; The latter parameter is only used in installation mode. ifint $(NetcardId) == $(PIT_ADAPTER_ID) set CardId = $(PIT_ADAPTER_ID) Shell "",SIDSVID ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set ProductHardwareTitle = $($R0) ifstr $(RiggedCB) == $(TRUE) set ProductHardwareTitle = "IBM 16/4 Token-Ring CardBus Adapter" endif ;check to see if we are installing cardbus adapter; if so, change feature mask to remove RNIC and add PE. set FeatureMask = "3892" ifstr $(ProductHardwareTitle) == "IBM 16/4 Token-Ring CardBus Adapter" set FeatureMask = "11828" endif SetINFDefaults =+ ; The following sections is used during a new installation and by ; the configure adapter section to determine the default values for ; parameters. ; ; Parameters needed: ; ; AdapterBusType REG_VT_DWORD 5 (1=ISA,3=MCA,5=PCI,8=PCMCIA) ; BusNumber REG_VT_DWORD ---> (set by PCI autodetect logic) ; BusType REG_VT_DWORD 5 (1=ISA,3=MCA,5=PCI,8=PCMCIA) ; CardId REG_VT_DWORD * ; DataRate REG_VT_SZ AUTO (AUTO,M16,M4) ; EnableTxEofInt REG_VT_SZ YES (YES,NO) ; FullDuplex REG_VT_SZ YES (YES,NO) ; LLCOnly REG_VT_SZ YES (YES,NO) ; LoopBack REG_VT_SZ NO (YES,NO) ; MaxTransmits REG_VT_DWORD 31 (1-128) ; MaxTxFrameSize REG_VT_DWORD 4096 (14-18000) ; MediaType REG_VT_DWORD 2 (1=Ethernet,2=Token Ring) ; MinRcvBuffs REG_VT_DWORD 40 (1-200) ; NetworkAddress REG_VT_SZ ** (12 digit valid LAA MAC address) ; RcvBuffSize REG_VT_DWORD 4096 (256-18000) ; SlotNumber REG_VT_DWORD ---> (set by PCI autodetect logic) ; TraceQuiet REG_VT_SZ **** (YES,NO) ; TxPriMax REG_VT_DWORD 6 (0-6) ; TxPriThresh REG_VT_DWORD 1 (1-6) ; ; * CardId is dependant on the actual card installed. Look in ; the file constant section for hints. ; ; ** NetworkAddress must be a valid LAA, that is, between 400000000000 and ; 7FFFFFFFFFFF hexidecimal. ; ; **** Needed only for NDIS 3.1 drivers, set in FillInValueList shell ; section. ; ; Set default values for first time install. This will set the default ; configuration for adapters that are being installed for the first time. ; The user can then bring up the properties for the adapter to configure the ; adapter after this has been done. ; If this driver can support SMP, do it. (Workstation must be running ; Windows NT 4.0 and have at least two processors). ; -- no longer used -- sgp 12 sept 1999 ; ; ifstr(i) $(hasSMP) == "YES" ; set SMP_Mode = "YES" ; else ; set SMP_Mode = "NO" ; endif ; Set the rest of the parameters set AdapterBusType = "5" ; PCI set BusType = "5" ; PCI set DataRate = "AUTO" set EnableTxEofInt = "YES" set FullDuplex = "YES" set LLCOnly = "YES" set LoopBack = "NO" set MaxTransmits = "31" set MaxTxFrameSize = "4096" set MediaType = "2" ; 802.5 Token Ring set MinRcvBuffs = "40" set NetworkAddress = "" set RcvBuffSize = "4096" ifstr $(SoftexCB) == $(TRUE) set SoftexPcmcia = "1" ;softex endif set TxPriMax = "6" set TxPriThresh = "1" set WebLink1_BT = "IBM Networking Home" set WebLink1_URL = "http://www.networking.ibm.com/" set WebLink2_BT = "IBM Networking Support" set WebLink2_URL = "http://www.networking.ibm.com/support/" set RTSWMode = "DISABLE" set RTSWHoldingTime = "20" set RTSWTableSize = "128" set RTSWSubnetMask = "0.0.0.0" ; The above section is called from Configure mode to reset common ; defaults for the driver. If called from configure, jump back to ; configuration section. ifstr(i) $(!NTN_InstallMode) == Configure goto AfterSetINFDefaults endif ; Create the Hardware Component Shell $(UtilityInf), AddHardwareComponent, + $(ProductHardwareName),+ $(STF_CONTEXTINFNAME),+ $(CurrentProductKeyName) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif Debug-Output "ProductKeyName ="$(CurrentProductKeyName) ifint $($R4) != -1 Set OEM_ABANDON_OPTIONS = >($(OEM_ABANDON_OPTIONS), $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$($R4)) endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != "NO_ERROR" EndWait CloseRegKey $($R1) CloseRegKey $($R2) CloseRegKey $($R3) goto FatalRegistry endif Set HardNetCardKey = $($R1) Set HardNetRuleKey = $($R2) Set HardParameterKey = $($R3) Set AdapterNumber = $($R4) Debug-Output "HardNetCardkey = "$(HardNetCardKey) Debug-Output "HardNetRuleKey = "$(HardNetRuleKey) Debug-Output "HardParameterKey = "$(HardParameterKey) Debug-Output "AdapterNumber = "$(AdapterNumber) Debug-Output "NetcardId = "$(NetcardId) Debug-Output "SlotNumber = "$(SlotNumber) ifstr $(SoftexCB) == $(TRUE) set AdapterName = $(ProductHardwareName)$(AdapterNumber) ;softex endif ; Here's where we set the pretty name of the driver. set MyTitle = "["$(AdapterNumber)"] "$(ProductHardwareTitle) Debug-Output "MyTitle = "$(MyTitle) Set MyService = $(ProductSoftwareName)$(AdapterNumber) Set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(CurrentManufacturer)},+ {Title,$(NoTitle),$(!REG_VT_SZ),$(MyTitle)},+ {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDescription)},+ {ProductName,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareName)},+ {ServiceName,$(NoTitle),$(!REG_VT_SZ),$($R5)},+ {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}} Debug-Output "NewValueList = "$(NewValueList) Debug-Output "HardNetCardKey = "$(HardNetCardKey) Shell $(UtilityInf), AddValueList, $(HardNetCardKey), $(NewValueList) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set TempProdName = """"$(ProductHardwareName)$(AdapterNumber)"""" set TempBindForm = $(TempProdName)$(NetRuleHardwareBindForm) set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleHardwareType)},+ {bindform,$(NoTitle),$(!REG_VT_SZ),$(TempBindForm)}, + {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleHardwareClass)}, + {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}} Debug-Output $(NewValueList) Debug-Output "TempProdName ="$(TempProdName) Debug-Output "HardNetRuleKey ="$(HardNetRuleKey) Shell $(UtilityInf), AddValueList, $(HardNetRuleKey), $(NewValueList) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif Shell "",FillInNewValueList ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set NewValueList = $($R0) Debug-Output "NewValueList = "$(NewValueList) Debug-Output "HardParameterKey = "$(HardParameterKey) Shell $(UtilityInf), AddValueList, $(HardParameterKey), $(NewValueList) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif ifstr(i) $(!STF_GUI_UNATTENDED) == "YES" Shell "" ,AddDefaultNetCardParameters,$(HardParameterKey) endif ;==Put these lines in here to set up the PCMCIA registry for CardWizzard ; -------------------------------------------------------------------------------- ; Write the parameters to the PCMCIA database section ; This is here for SystemSoft C&SSsupport ;; First do the IBMC1 ; -------------------------------------------------------------------------------- SET VERS1Product = "16/4 Token Ring CardBus" set PCMCIADatabaseKeyName = $(!NTN_ServiceBase)"\Pcmcia\DataBase" set PCMCIADatabaseMfgKeyName = $(PCMCIADatabaseKeyName)"\"$(Manufacturer) OpenRegKey $(!REG_H_LOCAL) "" $(PCMCIADatabaseKeyName) $(MAXIMUM_ALLOWED) PCMCIADatabaseKey ifstr $(PCMCIADatabaseKey) == $(NULL) ;Debug-Output "Pcmcia\DataBase not present" else ; PCMCIA.sys is installed and registry has database section in it. ; Try to open Manufacturer section. Delete it if found OpenRegKey $(!REG_H_LOCAL) "" $(PCMCIADatabaseKeyName)"\"$(Manufacturer) $(MAXIMUM_ALLOWED) PCMCIADatabaseMfgKey ifstr $(PCMCIADatabaseMfgKey) == $(NULL) ; open failed, so create Manufacturer subkey CreateRegKey $(PCMCIADatabaseKey) {$(Manufacturer), 0, 0} "" $(MAXIMUM_ALLOWED) "" PCMCIADatabaseMfgKey endif OpenRegKey $(!REG_H_LOCAL) "" $(PCMCIADatabaseMfgKeyName)"\"$(VERS1Product) $(MAXIMUM_ALLOWED) PCMCIADatabaseMfgC56Key ifstr $(PCMCIADatabaseMfgC56Key) == $(NULL) CreateRegKey $(PCMCIADatabaseMfgKey) {$(VERS1Product), 0, 0} "" $(MAXIMUM_ALLOWED) 0 PCMCIADatabaseMfgC56Key endif ; Set the values -------------------------------------------------------------------------------------- SetRegValue $(PCMCIADatabaseMfgC56Key) {Driver, 0, $(!REG_VT_SZ),"IBMTRP"} SetRegValue $(PCMCIADatabaseMfgC56Key) {DeviceType, 0, $(!REG_VT_SZ),"NET"} CloseRegKey $(PCMCIADatabaseMfgC56Key) CloseRegKey $(PCMCIADatabaseMfgKey) CloseRegKey $(PCMCIADatabaseKey) endif ;-- End of CardWizard additions CloseRegKey $(HardNetCardKey) CloseRegKey $(HardNetRuleKey) CloseRegKey $(HardParameterKey) NextAdapter = + EndForListDo LastAdapter = + EndWait FreeLibrary $(hDLL) goto successful ; ----------------------------------------------------------------- ; ConfigureAdapter - Entry point for configuration mode ; ----------------------------------------------------------------- ConfigureAdapter = + OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) NetCardKey ifstr(i) $(NetCardKey) == "" set CommonStatus = STATUS_USERCANCEL goto successful endif GetRegValue $(NetCardKey) "ServiceName" ServiceInfo set ServiceName = *($(ServiceInfo),4) GetRegValue $(NetCardKey) "Title" TitleInfo set MyTitle = *($(TitleInfo),4) CloseRegKey $(NetCardKey) OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(ServiceName)"\Parameters" $(MAXIMUM_ALLOWED) ParamKey ifstr(i) $(ParamKey) == "" goto successful endif ; Before going any further: is this adapter a secondary adapter ; in an RNIC situation? If so, stop the user from configuring ; anything and display a nice message. GetRegValue $(ParamKey) "PrimaryNIC" RNICValue ifint $(RegLastError) == "0" set Temp = *($(RNICValue), 4) ifint $(Temp) == "0" Debug-Output "User tried to configure secondary adapter. Naughty, naughty!" ; The adapter is secondary. Tell the user, then gracefully exit. set Error = "Secondary adapters in a redundant NIC relationship cannot be configured." set to = UnsupportedAction set from = UnsupportedAction goto UnsupportedAction else ; We are working on a Primary adapter in an RNIC relationship. ; RNICStatus = 1 set RNICStatus = "1" Debug-Output "Configuring Primary adapter in RNIC relationship." endif else ; We are a standalone adapter. RNICStatus = 0. set RNICStatus = "0" Debug-Output "Configuring standalone adapter." endif ; Set defaults for anything that can be changed in the GUI ; in case they aren't in the registry already. goto SetINFDefaults ;(in install section above) AfterSetINFDefaults = + ; Initialize ParmList set ParmList = "OptionID="$(Option)",MyTitle="$(MyTitle)",hasSMP="$(hasSMP)",DriverFile="$(DriverFile)",InstanceName="$(ServiceName) ; Read from the registry and override defaults with values we find ; there. EnumRegValue $(ParamKey) ValueList Debug-Output "ValueList ="$(ValueList) ForListDo $(ValueList) set ValueItem = $($) set Key = *($(ValueItem),1) set Value = *($(ValueItem),4) ifstr(i) $(Key) == "AdapterBusType" set AdapterBusType = $(Value) set ParmList = $(ParmList)",AdapterBusType="$(AdapterBusType) else-ifstr(i) $(Key) == "BusNumber" set BusNumber = $(Value) set ParmList = $(ParmList)",BusNumber="$(BusNumber) else-ifstr(i) $(Key) == "BusType" set BusType = $(Value) set ParmList = $(ParmList)",BusType="$(BusType) else-ifstr(i) $(Key) == "DataRate" set DataRate = $(Value) set ParmList = $(ParmList)",DataRate="$(DataRate) else-ifstr(i) $(Key) == "CardId" set CardId = $(Value) set ParmList = $(ParmList)",CardId="$(CardId) else-ifstr(i) $(Key) == "EnableTxEofInt" set EnableTxEofInt = $(Value) set ParmList = $(ParmList)",EnableTxEofInt="$(EnableTxEofInt) else-ifstr(i) $(Key) == "FeatureMask" set FeatureMask = $(Value) set ParmList = $(ParmList)",FeatureMask="$(FeatureMask) else-ifstr(i) $(Key) == "FullDuplex" set FullDuplex = $(Value) set ParmList = $(ParmList)",FullDuplex="$(FullDuplex) else-ifstr(i) $(Key) == "LLCOnly" set LLCOnly = $(Value) set ParmList = $(ParmList)",LLCOnly="$(LLCOnly) else-ifstr(i) $(Key) == "LoopBack" set LoopBack = $(Value) set ParmList = $(ParmList)",LoopBack="$(LoopBack) else-ifstr(i) $(Key) == "MaxTransmits" set MaxTransmits = $(Value) set ParmList = $(ParmList)",MaxTransmits="$(MaxTransmits) else-ifstr(i) $(Key) == "MaxTxFrameSize" set MaxTxFrameSize = $(Value) set ParmList = $(ParmList)",MaxTxFrameSize="$(MaxTxFrameSize) else-ifstr(i) $(Key) == "MediaType" set MediaType = $(Value) set ParmList = $(ParmList)",MediaType="$(MediaType) else-ifstr(i) $(Key) == "MinRcvBuffs" set MinRcvBuffs = $(Value) set ParmList = $(ParmList)",MinRcvBuffs="$(MinRcvBuffs) else-ifstr(i) $(Key) == "NetworkAddress" set NetworkAddress = $(Value) set ParmList = $(ParmList)",NetAddress="$(NetworkAddress) else-ifstr(i) $(Key) == "RcvBuffSize" set RcvBuffSize = $(Value) set ParmList = $(ParmList)",RcvBuffSize="$(RcvBuffSize) else-ifstr(i) $(Key) == "RTSWMode" set RTSWMode = $(Value) set ParmList = $(ParmList)",RTSWMode="$(RTSWMode) else-ifstr(i) $(Key) == "RTSWSubnetMask" set RTSWSubnetMask = $(Value) set ParmList = $(ParmList)",RTSWSubnetMask="$(RTSWSubnetMask) else-ifstr(i) $(Key) == "RTSWHoldingTime" set RTSWHoldingTime = $(Value) set ParmList = $(ParmList)",RTSWHoldingTime="$(RTSWHoldingTime) else-ifstr(i) $(Key) == "RTSWTableSize" set RTSWTableSize = $(Value) set ParmList = $(ParmList)",RTSWTableSize="$(RTSWTableSize) else-ifstr(i) $(Key) == "TCPPortRange1" set TCPPortRange1 = $(Value) set ParmList = $(ParmList)",TCPPortRange1="$(TCPPortRange1) else-ifstr(i) $(Key) == "TCPPortRange2" set TCPPortRange2 = $(Value) set ParmList = $(ParmList)",TCPPortRange2="$(TCPPortRange2) else-ifstr(i) $(Key) == "TCPPortRange3" set TCPPortRange3 = $(Value) set ParmList = $(ParmList)",TCPPortRange3="$(TCPPortRange3) else-ifstr(i) $(Key) == "TCPPortRange4" set TCPPortRange4 = $(Value) set ParmList = $(ParmList)",TCPPortRange4="$(TCPPortRange4) else-ifstr(i) $(Key) == "TCPPortRange5" set TCPPortRange5 = $(Value) set ParmList = $(ParmList)",TCPPortRange5="$(TCPPortRange5) else-ifstr(i) $(Key) == "UDPPortRange1" set UDPPortRange1 = $(Value) set ParmList = $(ParmList)",UDPPortRange1="$(UDPPortRange1) else-ifstr(i) $(Key) == "UDPPortRange2" set UDPPortRange2 = $(Value) set ParmList = $(ParmList)",UDPPortRange2="$(UDPPortRange2) else-ifstr(i) $(Key) == "UDPPortRange3" set UDPPortRange3 = $(Value) set ParmList = $(ParmList)",UDPPortRange3="$(UDPPortRange3) else-ifstr(i) $(Key) == "UDPPortRange4" set UDPPortRange4 = $(Value) set ParmList = $(ParmList)",UDPPortRange4="$(UDPPortRange4) else-ifstr(i) $(Key) == "UDPPortRange5" set UDPPortRange5 = $(Value) set ParmList = $(ParmList)",UDPPortRange5="$(UDPPortRange5) else-ifstr(i) $(Key) == "SlotNumber" set SlotNumber = $(Value) set ParmList = $(ParmList)",SlotNumber="$(SlotNumber) ; no longer used -- 12 sept 1999 sgp ; else-ifstr(i) $(Key) == "SMP_Mode" ; set SMP_Mode = $(Value) ; set ParmList = $(ParmList)",SMP_Mode="$(SMP_Mode) else-ifstr(i) $(Key) == "TxPriMax" set TxPriMax = $(Value) set ParmList = $(ParmList)",TxPriMax="$(TxPriMax) else-ifstr(i) $(Key) == "TxPriThresh" set TxPriThresh = $(Value) set ParmList = $(ParmList)",TxPriThresh="$(TxPriThresh) else-ifstr(i) $(Key) == "PairID" set PairID = $(Value) set ParmList = $(ParmList)",PairID="$(PairID) else-ifstr(i) $(Key) == "PrimaryNIC" set PrimaryNIC = $(Value) set ParmList = $(ParmList)",PrimaryNIC="$(PrimaryNIC) else-ifstr(i) $(Key) == "AdapterName" ;softex set AdapterName = $(Value) ;softex set ParmList = $(ParmList)",AdapterName="$(AdapterName) ;softex else-ifstr(i) $(Key) == "SoftexPcmcia" ;softex set SoftexPcmcia = $(Value) ;softex set ParmList = $(ParmList)",SoftexPcmcia="$(SoftexPcmcia) ;softex else-ifstr(i) $(Key) == "SoftexNetworkAddress" ;softex set SoftexNetworkAddress = $(Value) ;softex set ParmList = $(ParmList)",SoftexNetworkAddress="$(SoftexNetworkAddress) ;softex else-ifstr(i) $(Key) == "SoftexIO" ;softex set SoftexIO = $(Value) ;softex set ParmList = $(ParmList)",SoftexIO="$(SoftexIO) ;softex else-ifstr(i) $(Key) == "SoftexIRQ" ;softex set SoftexIRQ = $(Value) ;softex set ParmList = $(ParmList)",SoftexIRQ="$(SoftexIRQ) ;softex else-ifstr(i) $(Key) == "IOBaseAddress" set IOBaseAddress = $(Value) set ParmList = $(ParmList)",IOBaseAddress="$(IOBaseAddress) else-ifstr(i) $(Key) == "InterruptNumber" set InterruptNumber = $(Value) set ParmList = $(ParmList)",InterruptNumber="$(InterruptNumber) endif EndForListDo set ParmList = $(ParmList)",WebLink1_BT="$(WebLink1_BT) set ParmList = $(ParmList)",WebLink1_URL="$(WebLink1_URL) set ParmList = $(ParmList)",WebLink2_BT="$(WebLink2_BT) set ParmList = $(ParmList)",WebLink2_URL="$(WebLink2_URL) Debug-Output "ParmList ="$(ParmList) ; Save some values for RNIC. set Old_RNICStatus = $(RNICStatus) ifstr $(PairID) != "" set Old_PairID = $(PairID) set SecondaryInstance = $(ProductHardwareName)$(PairID) set Old_SecondaryInstance = $(SecondaryInstance) else set Old_PairID = $(RNIC_Not) set SecondaryInstance = $(RNIC_Not) set Old_SecondaryInstance = $(RNIC_Not) endif Debug-Output "RNICStatus = "$(RNICStatus)" Old_RNICStatus = "$(Old_RNICStatus) Debug-Output "PairID = "$(PairID)" Old_PairID = "$(Old_PairID) Debug-Output "SecondaryInstance = "$(SecondaryInstance)" Old_SecondaryInstance = "$(Old_SecondaryInstance) ; Load the ITR_W32 DLL and bring up the GUI LoadLibrary "X" $(InstallDLL) hDLL LibraryProcedure Result $(hDLL) InstallTokenRing $(ParmList) Debug-Output $(Result) ; Extract parameters from result string. We are only interested in ; the parameters that are changable from tokstp2 Split-String $(Result) "," ResultList ForListDo $(ResultList) Set Token = $($) ifstr $(Token) != "," Split-String $(Token) "=" KeyEqualsValue Set Key = *($(KeyEqualsValue), 1) Set Value = *($(KeyEqualsValue), 3) Debug-Output "Key = "$(Key)" Value = "$(Value) ifstr $(Key) == "STATUS" ifstr $(Value) != "OK" Set CommonStatus = STATUS_USERCANCEL Debug-Output "Cancel button pressed in InstallTokenRing()" goto end endif else-ifstr $(Key) == "AdapterBusType" set AdapterBusType = $(Value) else-ifstr $(Key) == "BusNumber" set BusNumber = $(Value) else-ifstr $(Key) == "BusType" set BusType = $(Value) else-ifstr $(Key) == "CardId" set CardId = $(Value) else-ifstr $(Key) == "DataRate" set DataRate = $(Value) else-ifstr $(Key) == "EnableTxEofInt" set EnableTxEofInt = $(Value) else-ifstr $(Key) == "FeatureMask" set FeatureMask = $(Value) else-ifstr $(Key) == "FullDuplex" set FullDuplex = $(Value) else-ifstr $(Key) == "LLCOnly" set LLCOnly = $(Value) else-ifstr $(Key) == "LoopBack" set LoopBack = $(Value) else-ifstr $(Key) == "MaxTransmits" set MaxTransmits = $(Value) else-ifstr $(Key) == "MaxTxFrameSize" set MaxTxFrameSize = $(Value) else-ifstr $(Key) == "MediaType" set MediaType = $(Value) else-ifstr $(Key) == "MinRcvBuffs" set MinRcvBuffs = $(Value) else-ifstr $(Key) == "NetAddress" set NetworkAddress = $(Value) else-ifstr $(Key) == "RcvBuffSize" set RcvBuffSize = $(Value) else-ifstr $(Key) == "RNICStatus" set RNICStatus = $(Value) else-ifstr $(Key) == "RNICVersion" set RNICVersion = $(Value) else-ifstr $(Key) == "RTSWMode" set RTSWMode = $(Value) else-ifstr $(Key) == "RTSWHoldingTime" set RTSWHoldingTime = $(Value) else-ifstr $(Key) == "RTSWTableSize" set RTSWTableSize = $(Value) else-ifstr $(Key) == "RTSWSubnetMask" set RTSWSubnetMask = $(Value) else-ifstr $(Key) == "TCPPortRange1" set TCPPortRange1 = $(Value) else-ifstr $(Key) == "TCPPortRange2" set TCPPortRange2 = $(Value) else-ifstr $(Key) == "TCPPortRange3" set TCPPortRange3 = $(Value) else-ifstr $(Key) == "TCPPortRange4" set TCPPortRange4 = $(Value) else-ifstr $(Key) == "TCPPortRange5" set TCPPortRange5 = $(Value) else-ifstr $(Key) == "UDPPortRange1" set UDPPortRange1 = $(Value) else-ifstr $(Key) == "UDPPortRange2" set UDPPortRange2 = $(Value) else-ifstr $(Key) == "UDPPortRange3" set UDPPortRange3 = $(Value) else-ifstr $(Key) == "UDPPortRange4" set UDPPortRange4 = $(Value) else-ifstr $(Key) == "UDPPortRange5" set UDPPortRange5 = $(Value) else-ifstr $(Key) == "SlotNumber" set SlotNumber = $(Value) ; no longer used -- 12 sept 1999 sgp ; else-ifstr $(Key) == "SMP_Mode" ; set SMP_Mode = $(Value) else-ifstr $(Key) == "TxPriMax" set TxPriMax = $(Value) else-ifstr $(Key) == "TxPriThresh" set TxPriThresh = $(Value) else-ifstr $(Key) == "PrimaryNIC" set PrimaryNIC = $(Value) else-ifstr $(Key) == "PairID" set PairID = $(Value) else-ifstr $(Key) == "AdapterName" set AdapterName = $(Value) else-ifstr $(Key) == "SoftexPcmcia" set SoftexPcmcia = $(Value) else-ifstr $(Key) == "SoftexNetworkAddress" set SoftexNetworkAddress = $(Value) endif endif EndForListDo ; Remove the parameters & rebuild the parameters based on user input EnumRegValue $(ParamKey) OldValueList ForListDo $(OldValueList) set ValueItem = $($) set ValueName = *($(ValueItem),1) DeleteRegValue $(ParamKey) $(ValueName) EndForListDo ; Build the new value list. Shell "",FillInNewValueList ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set NewParamList = $($R0) Shell $(UtilityInf), AddValueList, $(ParamKey), $(NewParamList) ; If we are doing Redundant NIC/QFO, we need to sync up the parameters ; RNIC Setup (NetRules/Internal Bookkeeping) ; CASE 1: If this is a new primary adapter in an RNIC situation, we need to ; do the following: ; ; (1a) find the secondary adapter's Parameter Key registry Handle, ; add the "RNICStatus" value to the parameter list and set ; it to "2" ; ; (1b) find the secondary adapter's NetRules Key registry Handle and ; remove the "type" value ; CASE 2: If this is a old primary adapter whose backup adapter has switched, ; then we need to do the following: ; ; (2a) find the old secondary adapter's Parameter Key registry Handle, ; change the "RNICStatus" value to "0" ; ; (2b) find the new secondary adapter's Parameter Key registry Handle, ; add the "RNICStatus" value to the parameter list and set ; it to "2" ; ; (2c) find the old secondary adapter's NetRules Key registry Handle and ; replace the "type" value ; ; (2d) find the secondary adapter's NetRules Key registry Handle and ; remove the "type" value ; CASE 3: Similarly, if this adapter was a primary, but is no longer a primary ; adapter, it's secondary must be fixed according to (2a) and (2b). ; Determine the cases here. Check to see if the Secondary instance changed. ifint $(PairID) > "0" set SecondaryInstance = $(ProductHardwareName)$(PairID) set RNICStatus = 1 else set SecondaryInstance = $(RNIC_Not) set RNICStatus = 0 endif Debug-Output "New PairID = "$(PairID)", New SecondaryInstance = "$(SecondaryInstance) Debug-Output "New RNICStatus = "$(RNICStatus) ifstr $(SecondaryInstance) != $(Old_SecondaryInstance) ; Set up some "informational strings" set PrimaryString = $(ProductHardwareDescription)" [Redundant NIC primary adapter, "$(SecondaryInstance)" acting as secondary]" set SecondaryString = $(ProductHardwareDescription)" [Redundant NIC secondary adapter]" ifint $(RNICStatus) == 1 ifint $(Old_RNICStatus) == 0 ; CASE 1: RNICStatus 0 >> 1 (New RNIC Setup) Debug-Output "RNIC Case 1 -- New RNIC Setup)" ; (1a) Open the secondary adapter's parameter key OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(SecondaryInstance)"\Parameters" $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif ; Save the secondary adapters BusNumber and SlotNumber values GetRegValue $(TempKey) "BusNumber" ValueList set SecondaryBusNumber = *($(ValueList),4) GetRegValue $(TempKey) "SlotNumber" ValueList set SecondarySlotNumber = *($(ValueList),4) ; Delete all of the secondary netcard's parameters and fill in the primary's parameters. EnumRegValue $(TempKey) OldValueList ForListDo $(OldValueList) set ValueItem = $($) set ValueName = *($(ValueItem),1) DeleteRegValue $(TempKey) $(ValueName) EndForListDo Shell $(UtilityInf), AddValueList, $(TempKey), $(NewParamList) ; Change the RNICStatus key to 2 (secondary). RNIC-2: Also set secondary adapter's PairID, as well ; as the value for PrimaryNIC (which should be zero, indicating a secondary adapter). --sgp set NewValueList = {{PairID,0,$(!REG_VT_DWORD),$(PairID)},+ {PrimaryNIC,0,$(!REG_VT_DWORD),0},+ {BusNumber,0,$(!REG_VT_DWORD),$(SecondaryBusNumber)},+ {SlotNumber,0,$(!REG_VT_DWORD),$(SecondarySlotNumber)}} Shell $(UtilityInf), AddValueList, $(TempKey) $(NewValueList) CloseRegKey $(TempKey) ; ; The following is no longer needed for RNIC-2, so it's commented out. ; (1b) Open the secondary adapter's NetRules key ;OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(SecondNum)"\NetRules" $(MAXIMUM_ALLOWED) TempKey ;Debug-Output $(!NTN_RegBase)"\NetRules" ;ifstr(i) $(TempKey) == "" ; goto fatal ;endif ; Delete the type value ;DeleteRegValue $(TempKey) type ;CloseRegKey $(TempKey) ;Set adapter descriptions for ease o' use. OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(PrimaryString)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(PairID) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(SecondaryString)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) else-ifint $(Old_RNICStatus) == 1 ; CASE 2: RNICStatus 1 >> 1 (Changed backup adapters) Debug-Output "RNIC Case 2 -- Existing RNIC Setup, Changed Secondary adapters" ; (2a) Open the old secondary adapter's parameter key OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(Old_SecondaryInstance)"\Parameters" $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif ; RNIC-2: Delete the PairID, Primary NIC, and NetworkAddress keys from the former secondary adapter. --sgp DeleteRegValue $(TempKey) PairID DeleteRegValue $(TempKey) PrimaryNIC DeleteRegValue $(TempKey) NetworkAddress CloseRegKey $(TempKey) ; (2b) Open the secondary adapter's parameter key OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(SecondaryInstance)"\Parameters" $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif ; Save the secondary adapters BusNumber and SlotNumber values GetRegValue $(TempKey) "BusNumber" ValueList set SecondaryBusNumber = *($(ValueList),4) GetRegValue $(TempKey) "SlotNumber" ValueList set SecondarySlotNumber = *($(ValueList),4) ; Delete all of the secondary netcard's parameters and fill in the primary's parameters. EnumRegValue $(TempKey) OldValueList ForListDo $(OldValueList) set ValueItem = $($) set ValueName = *($(ValueItem),1) DeleteRegValue $(TempKey) $(ValueName) EndForListDo Shell $(UtilityInf), AddValueList, $(TempKey), $(NewParamList) ; Change the RNICStatus key to 2 (secondary). RNIC-2: Also set secondary adapter's PairID, as well ; as the value for PrimaryNIC (which should be zero, indicating a secondary adapter). --sgp set NewValueList = {{PairID,0,$(!REG_VT_DWORD),$(PairID)},+ {PrimaryNIC,0,$(!REG_VT_DWORD),0},+ {BusNumber,0,$(!REG_VT_DWORD),$(SecondaryBusNumber)},+ {SlotNumber,0,$(!REG_VT_DWORD),$(SecondarySlotNumber)}} Shell $(UtilityInf), AddValueList, $(TempKey) $(NewValueList) CloseRegKey $(TempKey) ; No longer needed for RNIC-2, so it's commented out --sgp ;; (2c) Open the old secondary adapter's NetRules key ;OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(Old_SecondNum)"\NetRules" $(MAXIMUM_ALLOWED) TempKey ;ifstr(i) $(TempKey) == "" ; goto fatal ;endif ; Replace the type value ;set NewValueList = {type,0,$(!REG_VT_SZ),$(NetRuleHardwareType)} ;SetRegValue $(TempKey) $(NewValueList) ;CloseRegKey $(TempKey) ; (2d) Open the secondary adapter's NetRules key ;OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(SecondNum)"\NetRules" $(MAXIMUM_ALLOWED) TempKey ;ifstr(i) $(TempKey) == "" ; goto fatal ;endif ;; Delete the type value ;DeleteRegValue $(TempKey) type ;CloseRegKey $(TempKey) ; Set up descriptions for ease o' use... OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(PrimaryString)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(PairID) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(SecondaryString)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(Old_PairID) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(ProductHardwareDescription)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) endif else-ifint $(RNICStatus) == 0 ifint $(Old_RNICStatus) == 1 ; CASE 3: RNICStatus 1 >> 0 (Removed adapters from RNIC status) Debug-Output "RNIC Case 3 -- RNIC Dissolution" ; (3a) Open the secondary adapter's parameter key OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(Old_SecondaryInstance)"\Parameters" $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif ; RNIC-2: Delete the PairID, Primary NIC, and NetworkAddress keys from the former secondary adapter. --sgp DeleteRegValue $(TempKey) PairID DeleteRegValue $(TempKey) PrimaryNIC DeleteRegValue $(TempKey) NetworkAddress CloseRegKey $(TempKey) ; RNIC-2: no longer needed. --sgp ; (3b) Open the secondary adapter's NetRules key ;OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(Old_SecondNum)"\NetRules" $(MAXIMUM_ALLOWED) TempKey ;ifstr(i) $(TempKey) == "" ; goto fatal ;endif ;; Replace the type value ;set NewValueList = {type,0,$(!REG_VT_SZ),$(NetRuleHardwareType)} ;SetRegValue $(TempKey) $(NewValueList) ;CloseRegKey $(TempKey) ; Set up some informational strings OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(ProductHardwareDescription)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(Old_PairID) $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif set NewValueList = {Description,0,$(!REG_VT_SZ),$(ProductHardwareDescription)} SetRegValue $(TempKey) $(NewValueList) CloseRegKey $(TempKey) endif endif else ; If the secondary adapters are the same AND RNIC is active, we need to still sync ; up the registry entries for the pair. ifint $(RNICStatus) == 1 ; (2b) Open the secondary adapter's parameter key OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(SecondaryInstance)"\Parameters" $(MAXIMUM_ALLOWED) TempKey ifstr(i) $(TempKey) == "" goto fatal endif ; Save the secondary adapters BusNumber and SlotNumber values GetRegValue $(TempKey) "BusNumber" ValueList set SecondaryBusNumber = *($(ValueList),4) GetRegValue $(TempKey) "SlotNumber" ValueList set SecondarySlotNumber = *($(ValueList),4) ; Delete all of the secondary netcard's parameters and fill in the primary's parameters. EnumRegValue $(TempKey) OldValueList ForListDo $(OldValueList) set ValueItem = $($) set ValueName = *($(ValueItem),1) DeleteRegValue $(TempKey) $(ValueName) EndForListDo Shell $(UtilityInf), AddValueList, $(TempKey), $(NewParamList) ; Change the RNICStatus key to 2 (secondary). RNIC-2: Also set secondary adapter's PairID, as well ; as the value for PrimaryNIC (which should be zero, indicating a secondary adapter). --sgp set NewValueList = {{PairID,0,$(!REG_VT_DWORD),$(PairID)},+ {PrimaryNIC,0,$(!REG_VT_DWORD),0},+ {BusNumber,0,$(!REG_VT_DWORD),$(SecondaryBusNumber)},+ {SlotNumber,0,$(!REG_VT_DWORD),$(SecondarySlotNumber)}} Shell $(UtilityInf), AddValueList, $(TempKey) $(NewValueList) CloseRegKey $(TempKey) endif endif FreeLibrary $(hDLL) goto successful BindingAdapter =+ set Error = "Binding: Sorry, not yet implemented." goto fatal RemoveAdapter = + ; Find our parameter key OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) NetCardKey ifstr(i) $(NetCardKey) == "" goto FatalRegistry endif GetRegValue $(NetCardKey) "ServiceName" ServiceInfo set ServiceName = *($(ServiceInfo),4) OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(ServiceName)"\Parameters" $(MAXIMUM_ALLOWED) ParamKey ifstr(i) $(ParamKey) == "" goto FatalRegistry endif ; Before going any further: is this adapter a secondary adapter ; in an RNIC situation? If so, stop the user from configuring ; anything and display a nice message. GetRegValue $(ParamKey) "PrimaryNIC" RNICValue ifint $(RegLastError) == "0" set Temp = *($(RNICValue), 4) ifint $(Temp) == "0" ; The adapter is secondary. Tell the user, then gracefully exit. set Error = "Removing the secondary adapter in a redundant NIC pair is not supported. To uninstall this adapter, you must enter the Redundant NIC properties for the primary adapter in the redundant NIC pair and change the secondary adapter to 'Redundant NIC Disabled'. After doing this, you will be allowed to remove the adapter." set to = UnsupportedAction set from = UnsupportedAction goto UnsupportedAction else ; We are working on a Primary adapter in an RNIC relationship. ; Tell the user, then gracefully exit. set Error = "Removing the primary adapter in a redundant NIC pair is not supported. To uninstall this adapter, you must enter the Redundant NIC properties for this adapter and change the secondary adapter to 'Redundant NIC Disabled'. After doing this, you will be allowed to remove the adapter." set to = UnsupportedAction set from = UnsupportedAction goto UnsupportedAction endif else ; We are a standalone adapter. RNICStatus = 0. set RNICStatus = "0" endif CloseRegKey $(ParamKey) CloseRegKey $(NetCardKey) Debug-Output "Removing adapter components..." Ifstr(i) $(CurrentProductKeyName) == $(!NTN_RegBase) Shell $(UtilityInf), RemoveSoftwareComponent, + $(CurrentManufacturer), + $(ProductSoftwareName) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != NO_ERROR goto FatalRegistry endif else Shell $(UtilityInf), RemoveHardwareComponent, + $(CurrentManufacturer), + $(ProductSoftwareName), + $(!NTN_RegBase) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != NO_ERROR goto FatalRegistry endif endif goto end UpgradeSoftware = + Debug-Output "Entering Upgrade Software Section...\n" set KeyProduct = "" OpenRegKey $(!REG_H_LOCAL) "" $(CurrentProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct Ifstr(i) $(KeyProduct) != $(KeyNull) Debug-Output "Beginning upgrade of software component "$(KeyProduct) Shell $(UtilityInf), GetInfFileNameFromRegistry, $(KeyProduct) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set !UG_Filename = $($R0) install "Install-Update" ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS goto fatal endif ; Load the detection DLL -- we might need it -- LoadLibrary "X" $(InstallDLL) hDLL SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)} SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)} CloseRegKey $(KeyProduct) OpenRegKey $(!REG_H_LOCAL) "" $(NetworkDriverKeyName) $(MAXIMUM_ALLOWED) TempKey ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif SetRegValue $(TempKey) {ImagePath,0,$(!REG_VT_SZ),$(ProductSoftwareImagePath)} CloseRegKey $(TempKey) ; ; RNIC upgrade ; ; If any IBMTRP drivers are found to have implemented the earlier version ; of RNIC, we will attempt to "upgrade" their RNIC configuration with a ; minimum of user intervention. ; set RNICUpdated = 0 Debug-Output "Checking to see if RNIC pairs need to be upgraded...\n" ; Open the network cards key in the SOFTWARE section of the registry OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards" $(MAXIMUM_ALLOWED) NetCards ifstr(i) $(NetCards) == "" goto fatal endif ; Make a list of the installed network adapters EnumRegKey $(NetCards) NetCardList ; For each network adapter, determine if it is ours (e.g. IBMTRP) ForListDo $(NetCardList) set NetCardListItem = $($) set NetCardNumber = *($(NetCardListItem),1) OpenRegKey $(NetCards) "" $(NetCardNumber) $(MAXIMUM_ALLOWED) NetCardKey ifstr(i) $(NetCardKey) == "" Debug-Output "Could not open NetCardKey" goto fatal endif Debug-Output "1" GetRegValue $(NetCardKey) "ProductName" TestProductNameList Debug-Output "1a" set TestProductName = *($(TestProductNameList),4) ifstr $(ProductHardwareName) == $(TestProductName) ; This is an adapter we support. Let's get on with upgrading it's RNIC capabilities ; (if needed). First, open its parameters key. GetRegValue $(NetCardKey) "ServiceName" TestServiceNameList set TestServiceName = *($(TestServiceNameList),4) OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(TestServiceName)"\Parameters" $(MAXIMUM_ALLOWED) TestParamKey ifstr(i) $(TestParamKey) == "" Debug-Output "Could not open TestParamKey" goto fatal endif Debug-Output "2" set FeatureMask = "3892" SetRegValue $(TestParamKey) {FeatureMask,$(NoTitle),$(!REG_VT_DWORD),$(FeatureMask)} GetRegValue $(TestParamKey) "RNICStatus" TestRNICStatusList GetRegValue $(TestParamKey) "BusNumber" BusNumberList GetRegValue $(TestParamKey) "SlotNumber" SlotNumberList set TestRNICStatus = *($(TestRNICStatusList),4) set BusNumber = *($(BusNumberList),4) set SlotNumber = *($(SlotNumberList),4) Debug-Output "BusNumber = "$(BusNumber)" SlotNumber = "$(SlotNumber) ifstr $(TestRNICStatus) == "1" ; Ok, this adapter is a primary NIC in an old-style arrangement. We need ; to determine its secondary adapter instance name, and save its ordinal number. GetRegValue $(TestParamKey) "SecondaryInstance" TestSecondaryInstanceList set TestSecondaryInstance = *($(TestSecondaryInstanceList),4) Debug-Output "3a" Split-String $(TestSecondaryInstance) "P" HackedUp set SecondaryOrdinalNumber = *($(HackedUp), 3) Debug-Output "3b" ; Now, delete all those old-style RNIC keys DeleteRegValue $(TestParamKey) "SecondaryInstance" DeleteRegValue $(TestParamKey) "SecondaryBusNumber" DeleteRegValue $(TestParamKey) "SecondarySlotNumber" DeleteRegValue $(TestParamKey) "RNICStatus" ; Create new PairID and Primary NIC keys -- PairID equals SecondaryOrdinalNumber, ; PrimaryNIC = 1 set NewValueList = {{PairID,0,$(!REG_VT_DWORD),$(SecondaryOrdinalNumber)},+ {PrimaryNIC,0,$(!REG_VT_DWORD),1}} Shell $(UtilityInf), AddValueList $(TestParamKey) $(NewValueList) ; Done with Primary NIC. Now, open the primary adapter's secondary parameters and ; hardware key. We need to clone the primary adapter's parameter list into the ; secondary's parameter list, making sure that PrimaryNIC = 0 and BusNumber and ; slot number remain unchanged. ; ; Save all of the primary adapter's parameters to be cloned. Debug-Output "4" EnumRegValue $(TestParamKey) PrimaryParamList ; Close the primary adapter's parameter list CloseRegKey $(TestParamKey) ; Open the NetRules key and fix the bindings for the secondary adapter OpenRegKey $(!REG_H_LOCAL) "" "SOFTWARE\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$(SecondaryOrdinalNumber)"\NetRules" $(MAXIMUM_ALLOWED) SecondaryNetRules ifstr(i) $(SecondaryNetRules) == "" Debug-Output "Could not open SecondaryNetRules" goto fatal endif set NewValueList = {type,0,$(!REG_VT_SZ),$(NetRuleHardwareType)} SetRegValue $(SecondaryNetRules) $(NewValueList) CloseRegKey $(SecondaryNetRules) OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(TestSecondaryInstance)"\Parameters" $(MAXIMUM_ALLOWED) TestSecondaryParamKey ifstr(i) $(TestSecondaryParamKey) == "" Debug-Output "Could not open TestSecondaryParamKey" goto fatal endif ; Save the secondary adapter's bus and slot numbers ; Save the secondary adapters BusNumber and SlotNumber values GetRegValue $(TestSecondaryParamKey) "BusNumber" ValueList set SecondaryBusNumber = *($(ValueList),4) GetRegValue $(TestSecondaryParamKey) "SlotNumber" ValueList set SecondarySlotNumber = *($(ValueList),4) ; Delete all of the secondary netcard's parameters and fill in the primary's parameters. EnumRegValue $(TestSecondaryParamKey) OldValueList ForListDo $(OldValueList) set ValueItem = $($) set ValueName = *($(ValueItem),1) DeleteRegValue $(TempKey) $(ValueName) EndForListDo Shell $(UtilityInf), AddValueList $(TestSecondaryParamKey) $(PrimaryParamList) ; Add in secondary's proper bus and slot numbers set NewValueList = {{PairID,0,$(!REG_VT_DWORD),$(SecondaryOrdinalNumber)},+ {PrimaryNIC,0,$(!REG_VT_DWORD),0},+ {BusNumber,0,$(!REG_VT_DWORD),$(SecondaryBusNumber)},+ {SlotNumber,0,$(!REG_VT_DWORD),$(SecondarySlotNumber)}} Shell $(UtilityInf), AddValueList $(TestSecondaryParamKey) $(NewValueList) CloseRegKey $(TestSecondaryParamKey) set RNICUpdated = 1 endif ; ifstr $(RNICStatus) == "1" ; We also want to make the upgraded adapter have the correct title ; based on its sub-vendor id, etc. Shell "",SIDSVID ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set NewProductTitle = "["$(NetCardNumber)"] "$($R0) set NewValueList = {Title,0,$(!REG_VT_SZ),$(NewProductTitle)} SetRegValue $(NetCardKey) $(NewValueList) endif ; ifstr $(ProductHardwareName) == $(TestProductNameList) CloseRegKey $(NetCardKey) EndForListDo CloseRegKey $(NetCards) ifint $(RNICUpdated) == 1 set DlgType = "MessageBox" set STF_MB_TITLE = "QuickFailover Updated" set STF_MB_TEXT = "The existing RNIC configuration has been updated to work with the latest implementation of QuickFailover/RNIC. For best results, make sure that each secondary adapter in each pair is bound to at least one protocol. If a secondary adapter is using TCP/IP, make sure that it is assigned a bogus IP address." set STF_MB_TYPE = 1 set STF_MB_ICON = 3 set STF_MB_DEF = 1 ui start "Error Message" endif OpenRegKey $(!REG_H_LOCAL) "" "System\CurrentControlSet\Services\EventLog\System\"$(ProductHardwareName) $(MAXIMUM_ALLOWED) KeyEventLog ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif SetRegValue $(KeyEventLog) {EventMessageFile,$(NoTitle),$(!REG_VT_SZ),$(NetEventDLL)} CloseRegKey $(KeyEventLog) Debug-Output "Finished upgrade of software component "$(KeyProduct) FreeLibrary $(hDLL) else Debug-Output = "ACK! Can't find software component to upgrade...bailing out!" goto fatalregistry endif goto end UnsupportedAction = + Shell $(SubroutineInf) SetupMessage, $(!STF_LANGUAGE), "NONFATAL", $(Error) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set CommonStatus = STATUS_USERCANCEL goto end successful = + goto end abandon = + ForListDo $(OEM_ABANDON_OPTIONS) Shell $(UtilityInf), RemoveHardwareComponent, $(CurrentManufacturer), + $(ProductSoftwareName), $($) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != NO_ERROR goto FatalRegistry endif EndForListDo Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE Shell $(UtilityInf), RemoveSoftwareComponent, $(CurrentManufacturer), + $(ProductSoftwareName), FALSE ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set RegistryErrorIndex = $($R0) Ifstr(i) $(RegistryErrorIndex) != NO_ERROR goto FatalRegistry endif endif goto end warning = + Shell $(SubroutineInf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif ifstr(i) $($R1) == "OK" goto $(to) else-ifstr(i) $($R1) == "CANCEL" goto $(from) else goto "end" endif NonFatalInfo = + Set CommonStatus = STATUS_USERCANCEL Set Severity = STATUS goto NonFatalMsg nonfatal = + Set Severity = NONFATAL goto NonFatalMsg NonFatalMsg = + ifstr(i) $(Error) == "" Set Severity = NONFATAL Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL" ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set Error = $($R0) endif Shell $(SubroutineInf) SetupMessage, $(!STF_LANGUAGE), $(Severity), $(Error) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif ifstr(i) $($R1) == "OK" goto $(from) else goto "end" endif FatalRegistry = + Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set Error = $($R0) goto fatal fatal = + ifstr(i) $(Error) == "" Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL" ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif set Error = $($R0) endif Shell $(SubroutineInf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error) ifint $($ShellCode) != $(!SHELL_CODE_OK) goto ShellCodeError endif goto setfailed ShellCodeError = + set DlgType = "MessageBox" set STF_MB_TITLE = $(ShellCodeErrorTitle) set STF_MB_TEXT = $(ShellCodeErrorText) set STF_MB_TYPE = 1 set STF_MB_ICON = 3 set STF_MB_DEF = 1 ui start "Error Message" goto setfailed setfailed = + set CommonStatus = STATUS_FAILED ifstr(i) $(OEM_ABANDON_ON) == TRUE set OEM_ABANDON_ON = FALSE goto abandon endif goto end end = + goto term exit term = + Return $(CommonStatus) ;--------------------------------------------------------------------- ; Files sections [Files-NDIS4MP] 1, IBMTRP4.SY_, SIZE=66000, RENAME=IBMTRP.SYS [Files-NDIS3MP] 1, IBMTRP3.SY_, SIZE=66000, RENAME=IBMTRP.SYS [Files-SOFTEX] 1, IBMTRPX.SY_, SIZE=66000, RENAME=IBMTRP.SYS [Files-Support] 1, ITR_W32.DL_, SIZE=120000, RENAME=ITR_W32.DLL, OVERWRITE=VERIFYSOURCEOLDER 1, ITR.HL_, SIZE=20000, RENAME=ITR.HLP, OVERWRITE=VERIFYSOURCEOLDER 1, ITR.CN_, SIZE=1000, RENAME=ITR.CNT, OVERWRITE=VERIFYSOURCEOLDER 1, IBMSGNET.DL_, SIZE=1900, RENAME=IBMSGNET.DLL, OVERWRITE=VERIFYSOURCEOLDER [Files-INF] 1, OEMSETUP.INF, SIZE=71000, RENAME=$(!UG_Filename) ;--------------------------------------------------------------------- ; Installation Sections [Install-Option] set STF_VITAL = "" ifstr(i) $(NDIS_Level) == $(NDIS4_Level) ; WinNT 4.x ifstr $(SoftexCB) == $(TRUE) AddSectionFilesToCopyList Files-SOFTEX $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers else AddSectionFilesToCopyList Files-NDIS4MP $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers endif else ; assume WinNT 3.51 AddSectionFilesToCopyList Files-NDIS3MP $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers endif AddSectionFilesToCopyList Files-Support $(SrcDir) $(!STF_WINDOWSSYSPATH) set !STF_NCPA_FLUSH_COPYLIST = TRUE CopyFilesInCopyList AddFileToDeleteList $(!STF_WINDOWSSYSPATH)\IBMTRCPL.CPL AddFileToDeleteList $(!STF_WINDOWSSYSPATH)\IBMTRCPL.HLP Exit [Install-Update] set STF_VITAL = "" set STF_OVERWRITE = "VERIFYSOURCEOLDER" ifstr(i) $(NDIS_Level) == $(NDIS4_Level) ; WinNT 4.x AddSectionFilesToCopyList Files-NDIS4MP $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers else ; assume WinNT 3.51 AddSectionFilesToCopyList Files-NDIS3MP $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers endif AddSectionFilesToCopyList Files-Support $(SrcDir) $(!STF_WINDOWSSYSPATH) AddSectionFilesToCopyList Files-INF $(SrcDir) $(!STF_WINDOWSSYSPATH) set !STF_NCPA_FLUSH_COPYLIST = TRUE CopyFilesInCopyList AddFileToDeleteList $(!STF_WINDOWSSYSPATH)\IBMTRCPL.CPL AddFileToDeleteList $(!STF_WINDOWSSYSPATH)\IBMTRCPL.HLP exit ;--------------------------------------------------------------------- ; Shell sections used during installation [AddDefaultNetCardParameters] ; This section of code reads values out of the unattended install ; answer file, if any parameters exist. Answer file keywords ; are CASE SENSITIVE and will override any defaults which may ; have been already set in the INF, so be careful! set KeyParameter = $($0) ForListDo $(!NetCardParameterName) set Name = $($) set Value = *($(!NetCardParameterValue), $(#)) ifcontains(i) $(Name) in { + "NetworkAddress", + "LoopBack", + "FullDuplex", + "DataRate", + "EnableTxEofInt", + "LLCOnly", + ; "SMP_Mode", + ; not used anymore -- 12 sept 1999 sgp "RTSWMode", + "RTSWEnable", + "RTSWSubnetMask", + "TCPPortRange1", + "TCPPortRange2", + "TCPPortRange3", + "TCPPortRange4", + "TCPPortRange5", + "UDPPortRange1", + "UDPPortRange2", + "UDPPortRange3", + "UDPPortRange4", + "UDPPortRange5" + } set Type = $(!REG_VT_SZ) else set Type = $(!REG_VT_DWORD) endif Debug-Output "** Unattended Install: Answer File Parm Name = "$(Name)" with value = "$(Value) SetRegValue $(KeyParameter) {$(Name),0,$(Type),$(Value)} EndForListDo Return [FillInNewValueList] ; Build the new value list. Set NewValueList = {} Set List = {AdapterBusType,0,$(!REG_VT_DWORD),$(!P:AdapterBusType)} Set NewValueList = >($(NewValueList),$(List)) ifstr $(!P:BusNumber) != "" Set List = {BusNumber,0,$(!REG_VT_DWORD),$(!P:BusNumber)} Set NewValueList = >($(NewValueList),$(List)) endif Set List = {BusType,0,$(!REG_VT_DWORD),$(!P:BusType)} Set NewValueList = >($(NewValueList),$(List)) Set List = {CardId,0,$(!REG_VT_DWORD),$(!P:CardId)} Set NewValueList = >($(NewValueList),$(List)) ifstr $(!P:DataRate) != "" Set List = {DataRate,0,$(!REG_VT_SZ),$(!P:DataRate)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:EnableTxEofInt) != "" Set List = {EnableTxEofInt,0,$(!REG_VT_SZ),$(!P:EnableTxEofInt)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:FeatureMask) != "" Set List = {FeatureMask,0,$(!REG_VT_DWORD),$(!P:FeatureMask)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:FullDuplex) != "" Set List = {FullDuplex,0,$(!REG_VT_SZ),$(!P:FullDuplex)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:LLCOnly) != "" Set List = {LLCOnly,0,$(!REG_VT_SZ),$(!P:LLCOnly)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:LoopBack) != "" Set List = {LoopBack,0,$(!REG_VT_SZ),$(!P:LoopBack)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:MaxTransmits) != "" Set List = {MaxTransmits,0,$(!REG_VT_DWORD),$(!P:MaxTransmits)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:MaxTxFrameSize) != "" Set List = {MaxTxFrameSize,0,$(!REG_VT_DWORD),$(!P:MaxTxFrameSize)} Set NewValueList = >($(NewValueList),$(List)) endif Set List = {MediaType,0,$(!REG_VT_DWORD),$(!P:MediaType)} Set NewValueList = >($(NewValueList),$(List)) ifint $(!P:MinRcvBuffs) != "" Set List = {MinRcvBuffs,0,$(!REG_VT_DWORD),$(!P:MinRcvBuffs)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:NetworkAddress) != "" Set List = {NetworkAddress,0,$(!REG_VT_SZ),$(!P:NetworkAddress)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:RcvBuffSize) != "" Set List = {RcvBuffSize,0,$(!REG_VT_DWORD),$(!P:RcvBuffSize)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:RTSWMode) != "" Set List = {RTSWMode,0,$(!REG_VT_SZ),$(!P:RTSWMode)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:RTSWHoldingTime) != "" Set List = {RTSWHoldingTime,0,$(!REG_VT_DWORD),$(!P:RTSWHoldingTime)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:RTSWTableSize) != "" Set List = {RTSWTableSize,0,$(!REG_VT_DWORD),$(!P:RTSWTableSize)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:RTSWSubnetMask) != "" Set List = {RTSWSubnetMask,0,$(!REG_VT_SZ),$(!P:RTSWSubnetMask)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:TCPPortRange1) != "" Set List = {TCPPortRange1,0,$(!REG_VT_SZ),$(!P:TCPPortRange1)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:TCPPortRange2) != "" Set List = {TCPPortRange2,0,$(!REG_VT_SZ),$(!P:TCPPortRange2)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:TCPPortRange3) != "" Set List = {TCPPortRange3,0,$(!REG_VT_SZ),$(!P:TCPPortRange3)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:TCPPortRange4) != "" Set List = {TCPPortRange4,0,$(!REG_VT_SZ),$(!P:TCPPortRange4)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:TCPPortRange5) != "" Set List = {TCPPortRange5,0,$(!REG_VT_SZ),$(!P:TCPPortRange5)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:UDPPortRange1) != "" Set List = {UDPPortRange1,0,$(!REG_VT_SZ),$(!P:UDPPortRange1)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:UDPPortRange2) != "" Set List = {UDPPortRange2,0,$(!REG_VT_SZ),$(!P:UDPPortRange2)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:UDPPortRange3) != "" Set List = {UDPPortRange3,0,$(!REG_VT_SZ),$(!P:UDPPortRange3)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:UDPPortRange4) != "" Set List = {UDPPortRange4,0,$(!REG_VT_SZ),$(!P:UDPPortRange4)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:UDPPortRange5) != "" Set List = {UDPPortRange5,0,$(!REG_VT_SZ),$(!P:UDPPortRange5)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:PairID) != $(!P:RNIC_Not) ifstr $(!P:PairID) != "" ;set List = {SecondaryBusNumber,0,$(!REG_VT_DWORD),$(!P:SecondaryBusNumber)} ;set NewValueList = >($(NewValueList),$(List)) ;set List = {SecondarySlotNumber,0,$(!REG_VT_DWORD),$(!P:SecondarySlotNumber)} ;set NewValueList = >($(NewValueList),$(List)) set List = {PrimaryNIC,0,$(!REG_VT_DWORD),1} set NewValueList = >($(NewValueList),$(List)) set List = {PairID,0,$(!REG_VT_DWORD),$(!P:PairID)} set NewValueList = >($(NewValueList),$(List)) endif endif ifstr $(!P:SlotNumber) != "" Set List = {SlotNumber,0,$(!REG_VT_DWORD),$(!P:SlotNumber)} Set NewValueList = >($(NewValueList),$(List)) endif ; No longer used -- 12 sept 1999 sgp ; ifstr $(!P:SMP_Mode) != "" ; Set List = {SMP_Mode,0,$(!REG_VT_SZ),$(!P:SMP_Mode)} ; Set NewValueList = >($(NewValueList),$(List)) ; endif Set List = {TraceHead,0,$(!REG_VT_DWORD),$(!P:TraceHead)} Set NewValueList = >($(NewValueList),$(List)) ifint $(!P:TxPriMax) != "" Set List = {TxPriMax,0,$(!REG_VT_DWORD),$(!P:TxPriMax)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:TxPriThresh) != "" Set List = {TxPriThresh,0,$(!REG_VT_DWORD),$(!P:TxPriThresh)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:AdapterName) != "" Set List = {AdapterName,0,$(!REG_VT_SZ),$(!P:AdapterName)} Set NewValueList = >($(NewValueList),$(List)) endif ifstr $(!P:SoftexNetworkAddress) != "" Set List = {SoftexNetworkAddress,0,$(!REG_VT_SZ),$(!P:SoftexNetworkAddress)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:SoftexPcmcia) != "" Set List = {SoftexPcmcia,0,$(!REG_VT_DWORD),$(!P:SoftexPcmcia)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:SoftexIO) != "" Set List = {SoftexIO,0,$(!REG_VT_DWORD),$(!P:SoftexIO)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:SoftexIRQ) != "" Set List = {SoftexIRQ,0,$(!REG_VT_DWORD),$(!P:SoftexIRQ)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:IOBaseAddress) != "" Set List = {IOBaseAddress,0,$(!REG_VT_DWORD),$(!P:IOBaseAddress)} Set NewValueList = >($(NewValueList),$(List)) endif ifint $(!P:InterruptNumber) != "" Set List = {InterruptNumber,0,$(!REG_VT_DWORD),$(!P:InterruptNumber)} Set NewValueList = >($(NewValueList),$(List)) endif ; NDIS 3.1 Only Stuff Here ; ifstr(i) $(!P:NDIS_Level) == $(!P:NDIS3_Level) set List = {TraceQuiet,0,$(!REG_VT_SZ),"YES"} set NewValueList = >($(NewValueList),$(List)) endif Debug-Output "FillInNewValueList returning: "$(NewValueList) return $(NewValueList) ; ; SVID/SID detection ; [SIDSVID] ; ; Assume detection DLL loaded before section called! ; LibraryProcedure Result $(!P:hDLL) GetSIDSVID $(!P:BusNumber) $(!P:SlotNumber) Debug-Output "PCI SID/SVID of this card is "$(Result) ifstr(i) $(Result) == "1741014" set ProductHardwareTitle = "IBM High-Speed 100/16/4 Token-Ring PCI Management Adapter" else-ifstr(i) $(Result) == "1731014" set ProductHardwareTitle = "IBM 16/4 Token-Ring PCI Management Adapter with Alert on LAN" else-ifstr(i) $(Result) == "1721014" set ProductHardwareTitle = "IBM 16/4 Token-Ring PCI Management Adapter" else-ifstr(i) $(Result) == "1DB1014" set ProductHardwareTitle = "IBM 16/4 Token-Ring Low Profile PCI Management Adapter" else-ifstr(i) $(Result) == "1AF1014" set ProductHardwareTitle = "IBM 16/4 Token-Ring CardBus Adapter" else-ifstr(i) $(Result) == "E51014" set ProductHardwareTitle = "IBM 16/4 Token-Ring PCI Adapter 2 with Wake on LAN" else-ifstr(i) $(Result) == "E41014" set ProductHardwareTitle = "IBM High-Speed 100/16/4 Token-Ring PCI Adapter" else-ifstr(i) $(Result) == "CF1014" set ProductHardwareTitle = "IBM 16/4 Token-Ring PCI Special" else-ifstr(i) $(Result) == "CE1014" set ProductHardwareTitle = "IBM 16/4 Token-Ring PCI Adapter 2" else-ifstr(i) $(Result) == "CD1014" set ProductHardwareTitle = "IBM PCI Wake On LAN Token-Ring Adapter" else-ifstr(i) $(Result) == "3E1014" set ProductHardwareTitle = "IBM PCI Token-Ring Adapter" else-ifstr(i) $(Result) == "0" set ProductHardwareTitle = "IBM PCI Token-Ring Adapter" else set ProductHardwareTitle = "IBM PCI Token-Ring Adapter" endif return $(ProductHardwareTitle)Download Driver Pack
After your driver has been downloaded, follow these simple steps to install it.
Expand the archive file (if the download file is in zip or rar format).
If the expanded file has an .exe extension, double click it and follow the installation instructions.
Otherwise, open Device Manager by right-clicking the Start menu and selecting Device Manager.
Find the device and model you want to update in the device list.
Double-click on it to open the Properties dialog box.
From the Properties dialog box, select the Driver tab.
Click the Update Driver button, then follow the instructions.
Very important: You must reboot your system to ensure that any driver updates have taken effect.
For more help, visit our Driver Support section for step-by-step videos on how to install drivers for every file type.