From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 9EA0A7CDE for ; Fri, 22 Sep 2017 07:59:43 +0200 (CEST) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Sep 2017 22:59:42 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="1174729490" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga001.jf.intel.com with ESMTP; 21 Sep 2017 22:59:41 -0700 Received: from fmsmsx119.amr.corp.intel.com (10.18.124.207) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.319.2; Thu, 21 Sep 2017 22:59:41 -0700 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by FMSMSX119.amr.corp.intel.com (10.18.124.207) with Microsoft SMTP Server (TLS) id 14.3.319.2; Thu, 21 Sep 2017 22:59:41 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.175]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.152]) with mapi id 14.03.0319.002; Fri, 22 Sep 2017 13:59:39 +0800 From: "Wang, FeiX Y" To: "Liu, Yong" , "dts@dpdk.org" Thread-Topic: [dts] [Patch V1] framework/tester.py : add this function to support ixia to send fixed number of packets during certain period it is only for test_suite nic_single_core_perf, not for common use Thread-Index: AQHTM2bIcSaK/vX3XEyysIwgK2sj1aLAZ5wg Date: Fri, 22 Sep 2017 05:59:38 +0000 Message-ID: References: <1505910675-50844-1-git-send-email-feix.y.wang@intel.com> <86228AFD5BCD8E4EBFD2B90117B5E81E62EC98E9@SHSMSX103.ccr.corp.intel.com> In-Reply-To: <86228AFD5BCD8E4EBFD2B90117B5E81E62EC98E9@SHSMSX103.ccr.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dts] [Patch V1] framework/tester.py : add this function to support ixia to send fixed number of packets during certain period it is only for test_suite nic_single_core_perf, not for common use 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: , X-List-Received-Date: Fri, 22 Sep 2017 05:59:44 -0000 Hi, Yong Yes ,that's right, the value " runtime" is only to make sure all the packe= ts configured to be transmitted out within the period. Ok, then I will add a check to see if the actual transmitted packets is as = configured. Thanks fei =20 -----Original Message----- From: Liu, Yong=20 Sent: Friday, September 22, 2017 1:51 PM To: Wang, FeiX Y ; dts@dpdk.org Cc: Wang, FeiX Y Subject: RE: [dts] [Patch V1] framework/tester.py : add this function to su= pport ixia to send fixed number of packets during certain period it is only= for test_suite nic_single_core_perf, not for common use Fei, Please make sure your code align to pep style. I still has question for parameter "runTime", this value is depend on rate,= total number and link rate. I think the only value for this parameter is to make sure all packets trans= mitted. Why not just check how many packets emitted and return when equal to parame= ter "packetNum". Thanks, Marvin > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of wang fei > Sent: Wednesday, September 20, 2017 8:31 PM > To: dts@dpdk.org > Cc: Wang, FeiX Y > Subject: [dts] [Patch V1] framework/tester.py : add this function to=20 > support ixia to send fixed number of packets during certain period it=20 > is only for test_suite nic_single_core_perf, not for common use >=20 > Signed-off-by: wang fei > --- > framework/tester.py | 11 +++++++++++ > 1 file changed, 11 insertions(+) >=20 > diff --git a/framework/tester.py b/framework/tester.py index=20 > e7fb6bc..78202d0 100644 > --- a/framework/tester.py > +++ b/framework/tester.py > @@ -491,6 +491,17 @@ class Tester(Crb): >=20 > return out.rpartition('[')[0] >=20 > + def > traffic_generator_send_packets(self,portList,ratePercent,packetNum,del > ay=3D5 > ,runTime=3D60): > + """ > + send fixed number of packets on specified ports during=20 > + runTime > time. > + Be note that this function is only used for=20 > + nic_single_core_perf > test case, not for common use > + """ > + if self.check_port_list(portList, 'ixia'): > + return self.ixia_packet_gen.send_packets(portList, > ratePercent, packetNum,delay,runTime) > + if not self.check_port_list(portList): > + self.logger.warning("exception by mixed port types") > + return None > + > def traffic_generator_throughput(self, portList,=20 > rate_percent=3D100, > delay=3D5): > """ > Run throughput performance test on specified ports. > -- > 2.7.4