From: Jeremy Spewock <jspewock@iol.unh.edu>
To: Dean Marx <dmarx@iol.unh.edu>
Cc: probb@iol.unh.edu, npratte@iol.unh.edu, luca.vizzarro@arm.com,
yoan.picchi@foss.arm.com, Honnappa.Nagarahalli@arm.com,
paul.szczepanek@arm.com, juraj.linkes@pantheon.tech,
dev@dpdk.org
Subject: Re: [RFC v1 2/2] dts: checksum offload test suite
Date: Mon, 12 Aug 2024 16:55:14 -0400 [thread overview]
Message-ID: <CAAA20US8=4q=4i9fahyw9J5=ppkKG6bb2mUHnD289bFRwdSD0g@mail.gmail.com> (raw)
In-Reply-To: <20240812134124.27637-3-dmarx@iol.unh.edu>
On Mon, Aug 12, 2024 at 9:41 AM Dean Marx <dmarx@iol.unh.edu> wrote:
>
> test suite for verifying layer 3/4 checksum offload
> features on poll mode driver.
>
> Depends-on: patch-142762
> ("dts: add text parser for testpmd verbose output")
> Depends-on: patch-142691
> ("dts: add send_packets to test suites and rework packet addressing")
>
> Signed-off-by: Dean Marx <dmarx@iol.unh.edu>
> ---
> dts/framework/config/conf_yaml_schema.json | 3 +-
> dts/framework/remote_session/testpmd_shell.py | 2 +-
> dts/tests/TestSuite_checksum_offload.py | 288 ++++++++++++++++++
> 3 files changed, 291 insertions(+), 2 deletions(-)
> create mode 100644 dts/tests/TestSuite_checksum_offload.py
>
> diff --git a/dts/framework/config/conf_yaml_schema.json b/dts/framework/config/conf_yaml_schema.json
> index f02a310bb5..a83a6786df 100644
> --- a/dts/framework/config/conf_yaml_schema.json
> +++ b/dts/framework/config/conf_yaml_schema.json
> @@ -187,7 +187,8 @@
> "enum": [
> "hello_world",
> "os_udp",
> - "pmd_buffer_scatter"
> + "pmd_buffer_scatter",
> + "checksum_offload"
> ]
> },
> "test_target": {
> diff --git a/dts/framework/remote_session/testpmd_shell.py b/dts/framework/remote_session/testpmd_shell.py
> index be8fbdc295..01f378acc3 100644
> --- a/dts/framework/remote_session/testpmd_shell.py
> +++ b/dts/framework/remote_session/testpmd_shell.py
> @@ -856,7 +856,7 @@ def csum_set_hw(self, layer: str, port_id: int, verify: bool = True) -> None:
> InteractiveCommandExecutionError: If checksum offload is not enabled successfully.
> """
> csum_output = self.send_command(f"csum set {layer} hw {port_id}")
> - if (verify and ("Bad arguments" in csum_output or f"Please stop port {port_id} first")):
> + if (verify and ("Bad arguments" in csum_output or f"Please stop port {port_id} first" in csum_output)):
> self._logger.debug(f"Failed to set csum hw mode on port {port_id}:\n{csum_output}")
> raise InteractiveCommandExecutionError(
> f"Failed to set csum hw mode on port {port_id}"
It looks like some testpmd changes snuck into the git history for your
test suite, these probably belong in the previous commit.
<snip>
> +
> + def test_no_insert_checksums(self) -> None:
> + """Enable checksum offload insertion and verify packet reception."""
> + packet_list = [
> + Ether() / IP() / UDP() / Raw("xxxxx"),
> + Ether() / IP() / TCP() / Raw("xxxxx"),
In cases like this where the payload is used so many times, it
probably makes more sense to pull it out into its own variable.
> + Ether() / IPv6(src="::1") / UDP() / Raw("xxxxx"),
> + Ether() / IPv6(src="::1") / TCP() / Raw("xxxxx"),
> + ]
> + with TestPmdShell(node=self.sut_node, enable_rx_cksum=True) as testpmd:
> + testpmd.set_forward_mode(SimpleForwardingModes.csum)
> + testpmd.set_verbose(level=1)
> + testpmd.start()
> + self.send_packet_and_verify(packet_list=packet_list, load="xxxxx", should_receive=True)
> + for i in range(0, len(packet_list)):
> + self.send_packet_and_verify_checksum(
> + packet=packet_list[i], goodL4=True, goodIP=True, testpmd=testpmd
> + )
> +
<snip>
> 2.44.0
>
next prev parent reply other threads:[~2024-08-12 20:55 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-12 13:41 [RFC v1 0/2] dts: initial checksum offload suite Dean Marx
2024-08-12 13:41 ` [RFC v1 1/2] dts: add csum HW offload to testpmd shell Dean Marx
2024-08-12 20:55 ` Jeremy Spewock
2024-08-12 13:41 ` [RFC v1 2/2] dts: checksum offload test suite Dean Marx
2024-08-12 20:55 ` Jeremy Spewock [this message]
2024-08-12 20:54 ` [RFC v1 0/2] dts: initial checksum offload suite Jeremy Spewock
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAAA20US8=4q=4i9fahyw9J5=ppkKG6bb2mUHnD289bFRwdSD0g@mail.gmail.com' \
--to=jspewock@iol.unh.edu \
--cc=Honnappa.Nagarahalli@arm.com \
--cc=dev@dpdk.org \
--cc=dmarx@iol.unh.edu \
--cc=juraj.linkes@pantheon.tech \
--cc=luca.vizzarro@arm.com \
--cc=npratte@iol.unh.edu \
--cc=paul.szczepanek@arm.com \
--cc=probb@iol.unh.edu \
--cc=yoan.picchi@foss.arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).