summaryrefslogtreecommitdiffstats
path: root/vswitches/ovs_dpdk_vhost.py
diff options
context:
space:
mode:
authorAntonio Fischetti <antonio.fischetti@intel.com>2016-08-11 12:59:46 +0100
committerMaryam Tahhan <maryam.tahhan@intel.com>2016-10-09 12:03:01 +0000
commitda5b1633255f904f7d4f4c38c52df2f7f8e74092 (patch)
treed953d92d9a8b6dae2f3cf8cbd263d1ba729ace74 /vswitches/ovs_dpdk_vhost.py
parent270930fe5ce8634f0e9e6f6e838c92274739d814 (diff)
CLI: add Multiqueue params.
This patch implements the following new CLI parameters that can be used in the --test-params list. 1. guest_nic_queues, which overrides all GUEST_NIC_QUEUES values 2. guest_testpmd_txq, which overrides all GUEST_TESTPMD_TXQ 3. guest_testpmd_rxq, which overrides all GUEST_TESTPMD_RXQ 4. guest_testpmd_nb_cores, which overrides all GUEST_TESTPMD_NB_CORES values 5. guest_testpmd_cpu_mask, which overrides all GUEST_TESTPMD_CPU_MASK values 6. vswitch_dpdk_multi_queues, which overrides VSWITCH_DPDK_MULTI_QUEUES 7. guest_smp, which overrides all GUEST_SMP values 8. guest_core_binding, which overrides all GUEST_CORE_BINDING values When they are present in the CLI the corresponding settings from the configuration files will be overridden. As an example a usage can be: ./vsperf --test-params "guest_nic_queues=2;guest_testpmd_txq=1;\ guest_testpmd_rxq=1;guest_testpmd_nb_cores=1"... v2: rebase + rework to add other CLI params as suggested and update doc. v3: changes in 'testusage.rst' doc. JIRA: VSPERF-371 Change-Id: I140d6e068c1653d21aaa0df27532a48c4a12c151 Signed-off-by: Antonio Fischetti <antonio.fischetti@intel.com> Reviewed-by: Maryam Tahhan <maryam.tahhan@intel.com> Reviewed-by: Martin Klozik <martinx.klozik@intel.com>
Diffstat (limited to 'vswitches/ovs_dpdk_vhost.py')
-rw-r--r--vswitches/ovs_dpdk_vhost.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/vswitches/ovs_dpdk_vhost.py b/vswitches/ovs_dpdk_vhost.py
index 327a697d..5beb0051 100644
--- a/vswitches/ovs_dpdk_vhost.py
+++ b/vswitches/ovs_dpdk_vhost.py
@@ -22,6 +22,7 @@ import os
from src.ovs import OFBridge
from src.dpdk import dpdk
from conf import settings
+from conf import get_test_param
from vswitches.ovs import IVSwitchOvs
class OvsDpdkVhost(IVSwitchOvs):
@@ -69,6 +70,11 @@ class OvsDpdkVhost(IVSwitchOvs):
dpdk.init()
super(OvsDpdkVhost, self).start()
# old style OVS <= 2.5.0 multi-queue enable
+ vswitch_dpdk_multi_queues = \
+ int(get_test_param('vswitch_dpdk_multi_queues', 0))
+ if vswitch_dpdk_multi_queues:
+ settings.setValue('VSWITCH_DPDK_MULTI_QUEUES', \
+ vswitch_dpdk_multi_queues)
if settings.getValue('OVS_OLD_STYLE_MQ') and \
int(settings.getValue('VSWITCH_DPDK_MULTI_QUEUES')):
tmp_br = OFBridge(timeout=-1)