diff options
| author | Luca Vizzarro <[email protected]> | 2024-06-19 15:03:02 +0100 |
|---|---|---|
| committer | Thomas Monjalon <[email protected]> | 2024-06-20 05:33:13 +0200 |
| commit | fc0f7dc47ee35f7f6ea196331e27c3e088807092 (patch) | |
| tree | cdf105f45f1ff9cb02d0fb9ea2ebaf41e72f6aba /dts/framework/remote_session/testpmd_shell.py | |
| parent | 2b2f5a8aafb2970ac24747241d60614dcd771b14 (diff) | |
dts: add testpmd shell params
Implement all the testpmd shell parameters into a data structure.
Signed-off-by: Luca Vizzarro <[email protected]>
Reviewed-by: Paul Szczepanek <[email protected]>
Reviewed-by: Juraj Linkeš <[email protected]>
Reviewed-by: Jeremy Spewock <[email protected]>
Reviewed-by: Nicholas Pratte <[email protected]>
Diffstat (limited to 'dts/framework/remote_session/testpmd_shell.py')
| -rw-r--r-- | dts/framework/remote_session/testpmd_shell.py | 39 |
1 files changed, 3 insertions, 36 deletions
diff --git a/dts/framework/remote_session/testpmd_shell.py b/dts/framework/remote_session/testpmd_shell.py index e71cda406f..9deeb2a3a5 100644 --- a/dts/framework/remote_session/testpmd_shell.py +++ b/dts/framework/remote_session/testpmd_shell.py @@ -26,7 +26,7 @@ from typing import Callable, ClassVar from typing_extensions import Self from framework.exception import InteractiveCommandExecutionError -from framework.params.eal import EalParams +from framework.params.testpmd import SimpleForwardingModes, TestPmdParams from framework.parser import ParserFn, TextParser from framework.settings import SETTINGS from framework.utils import StrEnum @@ -56,37 +56,6 @@ class TestPmdDevice: return self.pci_address -class TestPmdForwardingModes(StrEnum): - r"""The supported packet forwarding modes for :class:`~TestPmdShell`\s.""" - - #: - io = auto() - #: - mac = auto() - #: - macswap = auto() - #: - flowgen = auto() - #: - rxonly = auto() - #: - txonly = auto() - #: - csum = auto() - #: - icmpecho = auto() - #: - ieee1588 = auto() - #: - noisy = auto() - #: - fivetswap = "5tswap" - #: - shared_rxq = "shared-rxq" - #: - recycle_mbufs = auto() - - class VLANOffloadFlag(Flag): """Flag representing the VLAN offload settings of a NIC port.""" @@ -646,9 +615,7 @@ class TestPmdShell(InteractiveShell): Also find the number of pci addresses which were allowed on the command line when the app was started. """ - self._app_params += " -i --mask-event intr_lsc" - - assert isinstance(self._app_params, EalParams) + assert isinstance(self._app_params, TestPmdParams) self.number_of_ports = ( len(self._app_params.ports) if self._app_params.ports is not None else 0 @@ -740,7 +707,7 @@ class TestPmdShell(InteractiveShell): self._logger.error(f"The link for port {port_id} did not come up in the given timeout.") return "Link status: up" in port_info - def set_forward_mode(self, mode: TestPmdForwardingModes, verify: bool = True): + def set_forward_mode(self, mode: SimpleForwardingModes, verify: bool = True): """Set packet forwarding mode. Args: |
