From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id B4F12A0555; Wed, 19 Feb 2020 08:05:49 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id AA4E41BF87; Wed, 19 Feb 2020 08:05:49 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id D024C3B5 for ; Wed, 19 Feb 2020 08:05:47 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 18 Feb 2020 23:05:47 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,459,1574150400"; d="scan'208";a="348875040" Received: from dpdk-moyufen06.sh.intel.com ([10.67.116.222]) by fmsmga001.fm.intel.com with ESMTP; 18 Feb 2020 23:05:46 -0800 From: yufengmx To: dts@dpdk.org, lijuan.tu@intel.com, lihongx.ma@intel.com Cc: yufengmx Date: Wed, 19 Feb 2020 15:08:55 +0800 Message-Id: <20200219070855.25471-2-yufengx.mo@intel.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20200219070855.25471-1-yufengx.mo@intel.com> References: <20200219070855.25471-1-yufengx.mo@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dts] [PATCH V1 1/1] optimize packet send and capture X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 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 Sender: "dts" optimize packet send and capture for x722. Signed-off-by: yufengmx --- tests/TestSuite_ipv4_reassembly.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/tests/TestSuite_ipv4_reassembly.py b/tests/TestSuite_ipv4_reassembly.py index 3f33809..8d69ac6 100644 --- a/tests/TestSuite_ipv4_reassembly.py +++ b/tests/TestSuite_ipv4_reassembly.py @@ -209,7 +209,7 @@ class TestIpReassembly(TestCase): self.tester.scapy_append( 'pcap = rdpcap("%s")' % self.test_config.pcap_file) self.tester.scapy_append( - 'sendp(pcap, iface="%s")' % self.test_config.tester_iface) + 'sendp(pcap, iface="%s", verbose=False)' % self.test_config.tester_iface) self.tester.scapy_execute() time.sleep(5) @@ -226,6 +226,12 @@ class TestIpReassembly(TestCase): os.remove(self.test_config.pcap_file) time.sleep(5) + @property + def wait_interval_for_tcpdump(self): + interval = 5 if self.nic in ["x722_37d2"] \ + else 0 + return interval + def tcpdump_start_sniffing(self): """ Starts tcpdump in the background to sniff the tester interface where @@ -238,12 +244,13 @@ class TestIpReassembly(TestCase): self.test_config.tester_iface) self.tester.send_expect('rm -f tcpdump.pcap', '#') self.tester.send_expect(command, '#') + time.sleep(self.wait_interval_for_tcpdump) def tcpdump_stop_sniff(self): """ Stops the tcpdump process running in the background. """ - + time.sleep(self.wait_interval_for_tcpdump) self.tester.send_expect('killall tcpdump', '#') # For the [pid]+ Done tcpdump... message after killing the process self.tester.send_expect('cat tcpdump.out', '#') -- 2.21.0