]> git.openfabrics.org - ~shefty/rdma-win.git/commitdiff
[WinOF] remove unused variables, do not wait for IPoIB device unless IPoIB and WSD...
authorStan Smith <stan.smith@intel.com>
Tue, 23 Feb 2010 23:10:26 +0000 (23:10 +0000)
committerStan Smith <stan.smith@intel.com>
Tue, 23 Feb 2010 23:10:26 +0000 (23:10 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1@2713 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

branches/WOF2-2/WinOF/WIX/CustomActions.vbs

index 80488a99e30997172695de7ddc9a48ec8cfb0caf..1cdea2c4a60074560b6be6d2062cf93ec2fadf39 100644 (file)
@@ -121,7 +121,7 @@ End Function
 ' A CA can only see Installer properties through pre-loaded 'CustomActionData'\r
 \r
 Sub WinOF_setup\r
-       dim VersionNT,Installed,AddLocal,use_this_HCA\r
+       dim VersionNT,Installed,AddLocal\r
 \r
        VersionNT = Session.Property("VersionNT")\r
        Installed = Session.Property("Installed")\r
@@ -133,7 +133,10 @@ Sub WinOF_setup
 \r
        If AddLocal = "" AND Installed = "" Then\r
                ' Enable default features.\r
-               AddLocal = "IBcore,hca_mthca,fIPoIB,fWSD,fDAPL,fDatBASIC1,fDatBASIC2" \r
+               AddLocal = "IBcore,fIPoIB,fDAPL,fDatBASIC1,fDatBASIC2,fND" \r
+               If VersionNT <> WindowsXP Then\r
+                       AddLocal = AddLocal & ",fWSD"\r
+               End If\r
        End If\r
 \r
        If Session.Property("OSM") = "1" OR Session.Property("OSMS") = "1" Then\r
@@ -314,7 +317,7 @@ End Sub
 Sub RemoveDriverFiles(fso,WshShell,VersionNT)\r
 \r
     Dim Win, sDRIVERS, sSYS32, sSYSWOW64\r
-    Dim CheckMode, PropArray, sTemp\r
+    Dim PropArray, sTemp\r
        \r
     ' Function can be called from the Driver{Install/Uninstall} rtns.\r
 \r
@@ -770,7 +773,7 @@ Function DriverInstall()
     ' Get the value of INSTALLDIR - see WinOF_Setup\r
     CheckMode = Session.Property("CustomActionData")\r
 \r
-    If Not CheckMode = "" Then\r
+    If CheckMode <> "" Then\r
         'in defered action this is the way to pass arguments.\r
            PropArray = Split(Session.Property("CustomActionData"), ";")\r
     Else\r
@@ -1534,6 +1537,9 @@ End Sub
 ' when ConnectX bus driver detects invalid Firmware hence does not create\r
 ' the PDO for the ConnectX HCA device so PNP never loads the HCA driver and\r
 ' complib.dll never gets installed.\r
+' If features[IPoIB+(WinSockDirect OR NetworkDirect)] are installed, then\r
+' wait for IPoIB device to appear in order to ensure WSD and/or ND provider\r
+' instal success.\r
 \r
 Sub CheckDriversOK()\r
     Dim winDir, WshShell, fso, AddLocal, too_long\r
@@ -1557,7 +1563,20 @@ Sub CheckDriversOK()
            Exit Sub\r
        End If\r
 \r
-       ' wait for IPoIB driver to start so ND & WSD can install\r
+       AddLocal = Session.Property("ADDLOCAL")\r
+\r
+       ' empty string implies default install Features which include IPoIB+WSD+ND.\r
+       If AddLocal <> "" Then\r
+               ' No wait if !IPoIB OR (!WinSockDirect AND !NetworkDirect)\r
+               If Instr(AddLocal,"fIPoIB") = 0 Then\r
+                       Exit Sub\r
+               End If\r
+               If Instr(AddLocal,"fWSD") = 0 AND Instr(AddLocal,"fND") = 0 Then\r
+                       Exit Sub\r
+               End If\r
+       End If\r
+\r
+       ' wait for IPoIB driver to start so ND and/or WSD can install\r
 \r
        devman = "cmd.exe /c cd /d " & sInstalldir & "Drivers & devman.exe "\r
 \r