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 58EC4A0551; Fri, 26 Aug 2022 04:43:17 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 54B1D41156; Fri, 26 Aug 2022 04:43:17 +0200 (CEST) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mails.dpdk.org (Postfix) with ESMTP id 01B20400D6 for ; Fri, 26 Aug 2022 04:43:15 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1661481796; x=1693017796; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=6lRey79aZwL4qwhZv0bcareSapFw94/VIv4P/ruSK8s=; b=JGZUcRrTic7vTujFU4coIOLYwRqrNRctjEwPihDNT2vRPOC2jacuAQqz sfvgN4NeyRBsVHN2PGUsg7l0AjsSCaTAY70ovhp42QO4vaQf/PN0dXI/D r7YYJCM8GAiou6PIQj90tIpi4I06FP4Voj9kPQkxomZBi9h6qPmOia31Q TNrBjAnFzyOKxnz/rvdRyHgTA1j0Bse7hMQFZK01bOKWXnOugO1l7yvte u7XghFQ9euQqK70JYr3tkFC+kyMpDZWnnDZRGvdkRDR4y8jfYuD9ep1+3 1r1vgJessHDPOq7QGLmf5LTi7jYbTha4EJc8g70aMFh0x5FjN8YZo7CFu Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10450"; a="295187360" X-IronPort-AV: E=Sophos;i="5.93,264,1654585200"; d="scan'208";a="295187360" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Aug 2022 19:43:15 -0700 X-IronPort-AV: E=Sophos;i="5.93,264,1654585200"; d="scan'208";a="671275208" Received: from unknown (HELO localhost.localdomain) ([10.239.252.248]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Aug 2022 19:43:14 -0700 From: Weiyuan Li To: dts@dpdk.org Cc: Weiyuan Li , Jiale Song Subject: [dts][PATCH V2 06/10] tests/ice_advanced_rss: update dts code for dpdk csum change Date: Fri, 26 Aug 2022 10:43:04 +0800 Message-Id: <20220826024308.17447-6-weiyuanx.li@intel.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20220826024308.17447-1-weiyuanx.li@intel.com> References: <20220826024308.17447-1-weiyuanx.li@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org According to dpdk commit 9b4ea7ae77fa(app/testpmd: revert MAC update in checksum forwarding) modify the script adapt to this chagne. 1. Modify VF case to enable promisc. 2. Modify PF case to send packet dst mac is random. Signed-off-by: Weiyuan Li --- Tested-by: Jiale Song < songx.jiale@intel.com> v2: -modify the dst mac variable to 'dst_mac' tests/TestSuite_ice_advanced_rss.py | 31 +++++++++++++++-------------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/tests/TestSuite_ice_advanced_rss.py b/tests/TestSuite_ice_advanced_rss.py index 0c246cca..a3318101 100644 --- a/tests/TestSuite_ice_advanced_rss.py +++ b/tests/TestSuite_ice_advanced_rss.py @@ -5493,7 +5493,7 @@ class AdvancedRSSTest(TestCase): expect_chksum = dict() checksum_pattern = re.compile("chksum.*=.*(0x[0-9a-z]+)") self.tester.send_expect("scapy", ">>> ") - sniff_src = self.dut.get_mac_address(self.dut_ports[0]) + sniff_src = "52:00:00:00:00:00" for pkt in expect_pkts: self.tester.send_expect("p = %s" % expect_pkts[pkt], ">>>") out = self.tester.send_expect("p.show2()", ">>>") @@ -5541,23 +5541,24 @@ class AdvancedRSSTest(TestCase): self.pmd_output.execute_cmd("csum set sctp hw 0") self.pmd_output.execute_cmd("port start all") self.pmd_output.execute_cmd("start") + dst_mac = "00:11:22:33:44:56" pkt_list = { - "IP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1", chksum=0xfff3)/("X"*48)', - "IP/TCP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/TCP(sport=22, chksum=0xfff3)/("X"*48)', - "IP/UDP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/UDP(sport=22, chksum=0x1)/("X"*48)', - "IP/SCTP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/SCTP(sport=22, chksum=0x0)/("X"*48)', - "IPv6/TCP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IPv6()/TCP(sport=22, chksum=0xe38)/("X"*48)', - "IPv6/UDP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IPv6()/UDP(sport=22, chksum=0xe38)/("X"*48)', - "IPv6/SCTP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IPv6()/SCTP(sport=22, chksum=0x0)/("X"*48)', + "IP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1", chksum=0xfff3)/("X"*48)', + "IP/TCP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/TCP(sport=22, chksum=0xfff3)/("X"*48)', + "IP/UDP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/UDP(sport=22, chksum=0x1)/("X"*48)', + "IP/SCTP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/SCTP(sport=22, chksum=0x0)/("X"*48)', + "IPv6/TCP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IPv6()/TCP(sport=22, chksum=0xe38)/("X"*48)', + "IPv6/UDP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IPv6()/UDP(sport=22, chksum=0xe38)/("X"*48)', + "IPv6/SCTP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IPv6()/SCTP(sport=22, chksum=0x0)/("X"*48)', } expect_pkt = { - "IP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/("X"*48)', - "IP/TCP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/TCP(sport=22)/("X"*48)', - "IP/UDP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/UDP(sport=22)/("X"*48)', - "IP/SCTP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/SCTP(sport=22)/("X"*48)', - "IPv6/TCP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IPv6()/TCP(sport=22)/("X"*48)', - "IPv6/UDP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IPv6()/UDP(sport=22)/("X"*48)', - "IPv6/SCTP": 'Ether(dst="00:11:22:33:44:55", src="52:00:00:00:00:00")/IPv6()/SCTP(sport=22)/("X"*48)', + "IP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/("X"*48)', + "IP/TCP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/TCP(sport=22)/("X"*48)', + "IP/UDP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/UDP(sport=22)/("X"*48)', + "IP/SCTP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IP(src="192.168.0.1")/SCTP(sport=22)/("X"*48)', + "IPv6/TCP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IPv6()/TCP(sport=22)/("X"*48)', + "IPv6/UDP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IPv6()/UDP(sport=22)/("X"*48)', + "IPv6/SCTP": f'Ether(dst="{dst_mac}", src="52:00:00:00:00:00")/IPv6()/SCTP(sport=22)/("X"*48)', } rule_list = [ "flow create 0 ingress pattern eth / ipv4 / end actions rss types ipv4-chksum end queues end / end", -- 2.25.1