dpdk_shell - DPDK Interactive Remote Shell
Base interactive shell for DPDK applications.
Provides a base class to create interactive shells based on DPDK.
- compute_eal_params(sut_node: SutNode, params: framework.params.eal.EalParams | None = None, lcore_filter_specifier: framework.testbed_model.cpu.LogicalCoreCount | framework.testbed_model.cpu.LogicalCoreList = LogicalCoreCount(lcores_per_core=1, cores_per_socket=2, socket_count=1, sockets=None), ascending_cores: bool = True, append_prefix_timestamp: bool = True) EalParams
Compute EAL parameters based on the node’s specifications.
- Parameters:
sut_node (SutNode) – The SUT node to compute the values for.
params (framework.params.eal.EalParams | None) – If
None
, a new object is created and returned. Otherwise params.lcore_list is modified according to lcore_filter_specifier. A DPDK file prefix is also added. If params.ports isNone
, then sut_node.ports is assigned to it.lcore_filter_specifier (framework.testbed_model.cpu.LogicalCoreCount | framework.testbed_model.cpu.LogicalCoreList) – A number of lcores/cores/sockets to use or a list of lcore ids to use. The default will select one lcore for each of two cores on one socket, in ascending order of core ids.
ascending_cores (bool) – Sort cores in ascending order (lowest to highest IDs). If
False
, sort in descending order.append_prefix_timestamp (bool) – If
True
, will append a timestamp to DPDK file prefix.
- class DPDKShell
Bases:
SingleActiveInteractiveShell
,ABC
The base class for managing DPDK-based interactive shells.
This class shouldn’t be instantiated directly, but instead be extended. It automatically injects computed EAL parameters based on the node in the supplied app parameters.
- __init__(node: SutNode, privileged: bool = True, timeout: float = 15, lcore_filter_specifier: framework.testbed_model.cpu.LogicalCoreCount | framework.testbed_model.cpu.LogicalCoreList = LogicalCoreCount(lcores_per_core=1, cores_per_socket=2, socket_count=1, sockets=None), ascending_cores: bool = True, append_prefix_timestamp: bool = True, app_params: EalParams = EalParams(lcore_list=None, memory_channels=None, prefix='dpdk', no_pci=None, vdevs=None, allowed_ports=None, blocked_ports=None, other_eal_param=None, _separator=True), name: str | None = None) None
Extends
__init__()
.Adds the lcore_filter_specifier, ascending_cores and append_prefix_timestamp arguments which are then used to compute the EAL parameters based on the node’s configuration.