From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5E688457A5; Mon, 12 Aug 2024 22:55:28 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4EC0640E43; Mon, 12 Aug 2024 22:55:28 +0200 (CEST) Received: from mail-pj1-f54.google.com (mail-pj1-f54.google.com [209.85.216.54]) by mails.dpdk.org (Postfix) with ESMTP id F32CE402BB for ; Mon, 12 Aug 2024 22:55:26 +0200 (CEST) Received: by mail-pj1-f54.google.com with SMTP id 98e67ed59e1d1-2cb4c584029so3711823a91.3 for ; Mon, 12 Aug 2024 13:55:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iol.unh.edu; s=unh-iol; t=1723496126; x=1724100926; darn=dpdk.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=Fi7JLumPkDgN+kqasVfpVtN+xb2gtwq8ktsVZF46+uo=; b=KjlOU4DMsX97F+P0CZCVXBEYIdijNg790zkIPIxg2ND7Z5CgmuT3vClMTVxy1ndMbk D07NX88deStnGmlpkXILfJmL85M5XXgjgtt5QsaGdzA6BsknNYL2MVkANQZQ+e27MZni l8kHACvoJenODk5wV3k25k6cEBSvQImgHCe8M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723496126; x=1724100926; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Fi7JLumPkDgN+kqasVfpVtN+xb2gtwq8ktsVZF46+uo=; b=dNqsrqdpqDqkD6JrjDp5jv8bY4oOKyPAJbjdg+Y6PWpoZBukectzh1xaeCbW7+XamW VcWfXCreMJ3plB2defm1T9aIGEBLJmxmRAbWwXgy/wZld71kpWfDfUHFU1blPjDW/ciy 9HKMz05DGm7QSjqcRjuIiMNIXqDOpCvp9yXsxJ2L7MVfVm6Pu5SEnBNwCK4Qsv+y54O7 EzUrqSPqEU4+rOf3s/8eG7ReUi0TEweMFtW0WqxZeJHED9r1KIaHDAdHFp1ONlPSGFDg STIFJhPoaFdvhGbwJS57NBAPKrNO6bFgXfhX8O4Rcyr52BvTgrdZml/inEwqnBCm6F3R 80tg== X-Forwarded-Encrypted: i=1; AJvYcCX+JqWfkStWTC6cU9viMWisJHt9GiOfQa8hWxHQ8wZoHmzvVva17TLCcPXAjmsAusS3HDjI2yDboGo8ctY= X-Gm-Message-State: AOJu0YwvSSq856Fgw5Y9Q+2sNpE7uYnIRk7YneIsOGr1OMTRxmQvveyY sADPdi4rM2JIkP+mNptPliLKvst39sXVLPQaBfhHenD+66atT3PZhiP/OBt0Av7umRYvG1F0TRU HOE4vkFunvSKkhhQ8cA7Yhu5BE1rBSl+zrC9KdQ== X-Google-Smtp-Source: AGHT+IGqA/4vqySXtDs9kBOOOYM13T8m0G6ljoXRpY24IpMDP28PVAR5OMGZTGRw5adWLPcVK+YHkZFAjy0b9Sr4ha8= X-Received: by 2002:a17:90b:4c4c:b0:2d1:bf48:e767 with SMTP id 98e67ed59e1d1-2d3926380damr1577896a91.29.1723496125983; Mon, 12 Aug 2024 13:55:25 -0700 (PDT) MIME-Version: 1.0 References: <20240812134124.27637-1-dmarx@iol.unh.edu> <20240812134124.27637-3-dmarx@iol.unh.edu> In-Reply-To: <20240812134124.27637-3-dmarx@iol.unh.edu> From: Jeremy Spewock Date: Mon, 12 Aug 2024 16:55:14 -0400 Message-ID: Subject: Re: [RFC v1 2/2] dts: checksum offload test suite To: Dean Marx 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 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Mon, Aug 12, 2024 at 9:41=E2=80=AFAM Dean Marx 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 > --- > 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/c= onfig/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/framewor= k/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, verif= y: bool =3D True) -> None: > InteractiveCommandExecutionError: If checksum offload is not= enabled successfully. > """ > csum_output =3D 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 {por= t_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. > + > + def test_no_insert_checksums(self) -> None: > + """Enable checksum offload insertion and verify packet reception= .""" > + packet_list =3D [ > + 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=3D"::1") / UDP() / Raw("xxxxx"), > + Ether() / IPv6(src=3D"::1") / TCP() / Raw("xxxxx"), > + ] > + with TestPmdShell(node=3Dself.sut_node, enable_rx_cksum=3DTrue) = as testpmd: > + testpmd.set_forward_mode(SimpleForwardingModes.csum) > + testpmd.set_verbose(level=3D1) > + testpmd.start() > + self.send_packet_and_verify(packet_list=3Dpacket_list, load= =3D"xxxxx", should_receive=3DTrue) > + for i in range(0, len(packet_list)): > + self.send_packet_and_verify_checksum( > + packet=3Dpacket_list[i], goodL4=3DTrue, goodIP=3DTru= e, testpmd=3Dtestpmd > + ) > + > 2.44.0 >