Merge "sriov: Determine path to the bind-tool"
[vswitchperf.git] / vsperf
diff --git a/vsperf b/vsperf
index 68a961e..5589ac3 100755 (executable)
--- a/vsperf
+++ b/vsperf
@@ -387,6 +387,9 @@ def enable_sriov(nic_list):
                 else:
                     _LOGGER.debug("SRIOV enabled for NIC %s", nic)
 
+                # ensure that path to the bind tool is valid
+                functions.settings_update_paths()
+
                 # WORKAROUND: it has been observed with IXGBE(VF) driver,
                 # that NIC doesn't correclty dispatch traffic to VFs based
                 # on their MAC address. Unbind and bind to the same driver
@@ -564,8 +567,8 @@ def main():
 
     settings.setValue('mode', args['mode'])
 
-    # set dpdk and ovs paths according to VNF and VSWITCH
-    if settings.getValue('mode') != 'trafficgen':
+    # update paths to trafficgens if required
+    if settings.getValue('mode') == 'trafficgen':
         functions.settings_update_paths()
 
     # if required, handle list-* operations