aboutsummaryrefslogtreecommitdiffstats
path: root/resources/libraries/python/topology.py
diff options
context:
space:
mode:
authorKirill Rybalchenko <kirill.rybalchenko@intel.com>2016-12-21 12:16:29 +0000
committerPeter Mikus <pmikus@cisco.com>2017-04-10 04:34:04 +0000
commit4e421686933355ddc6ce0780efd15041c60de7e3 (patch)
tree1c8963efdd3fbaf0ea21411b0466414e92e2642f /resources/libraries/python/topology.py
parent2e115ad11cca45b11c0f1949fd8c42fec899bb68 (diff)
IPsec Multi-Tunnel performance test suite
Change-Id: I4b0ba83960e50089f29cab9a30ab760241c6f566 Signed-off-by: Kirill Rybalchenko <kirill.rybalchenko@intel.com>
Diffstat (limited to 'resources/libraries/python/topology.py')
-rw-r--r--resources/libraries/python/topology.py29
1 files changed, 29 insertions, 0 deletions
diff --git a/resources/libraries/python/topology.py b/resources/libraries/python/topology.py
index 8a591dfd14..791b07053c 100644
--- a/resources/libraries/python/topology.py
+++ b/resources/libraries/python/topology.py
@@ -39,6 +39,7 @@ def load_topo_from_yaml():
# pylint: disable=invalid-name
+
class NodeType(object):
"""Defines node types used in topology dictionaries."""
# Device Under Test (this node has VPP running on it)
@@ -805,6 +806,34 @@ class Topology(object):
return node['host']
@staticmethod
+ def get_cryptodev(node):
+ """Return Crytodev configuration of the node.
+
+ :param node: Node created from topology.
+ :type node: dict
+ :return: Cryptodev configuration string.
+ :rtype: str
+ """
+ try:
+ return node['cryptodev']
+ except KeyError:
+ return None
+
+ @staticmethod
+ def get_uio_driver(node):
+ """Return uio-driver configuration of the node.
+
+ :param node: Node created from topology.
+ :type node: dict
+ :return: uio-driver configuration string.
+ :rtype: str
+ """
+ try:
+ return node['uio_driver']
+ except KeyError:
+ return None
+
+ @staticmethod
def set_interface_numa_node(node, iface_key, numa_node_id):
"""Set interface numa_node location.