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 DA55C5A37 for ; Wed, 20 May 2015 10:10:05 +0200 (CEST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP; 20 May 2015 01:10:04 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,464,1427785200"; d="scan'208";a="574133539" Received: from pgsmsx102.gar.corp.intel.com ([10.221.44.80]) by orsmga003.jf.intel.com with ESMTP; 20 May 2015 01:10:04 -0700 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by PGSMSX102.gar.corp.intel.com (10.221.44.80) with Microsoft SMTP Server (TLS) id 14.3.224.2; Wed, 20 May 2015 16:10:03 +0800 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.23]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.94]) with mapi id 14.03.0224.002; Wed, 20 May 2015 16:10:02 +0800 From: "Liu, Yong" To: "Xu, HuilongX" , "dts@dpdk.org" Thread-Topic: [dts] [dts v1] support dpdk2.0 code Thread-Index: AQHQksa/e6NEFnF0XU2EQ9nOG28frp2EeR/wgAAJjVA= Date: Wed, 20 May 2015 08:10:01 +0000 Message-ID: <86228AFD5BCD8E4EBFD2B90117B5E81E10E1E9FB@SHSMSX103.ccr.corp.intel.com> References: <1432103524-7743-1-git-send-email-huilongx.xu@intel.com> <86228AFD5BCD8E4EBFD2B90117B5E81E10E1DBB0@SHSMSX103.ccr.corp.intel.com> In-Reply-To: <86228AFD5BCD8E4EBFD2B90117B5E81E10E1DBB0@SHSMSX103.ccr.corp.intel.com> Accept-Language: zh-CN, 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] [dts v1] support dpdk2.0 code 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: Wed, 20 May 2015 08:10:06 -0000 Some additional comments. > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Liu, Yong > Sent: Wednesday, May 20, 2015 4:00 PM > To: Xu, HuilongX; dts@dpdk.org > Subject: Re: [dts] [dts v1] support dpdk2.0 code >=20 > Huilong, >=20 > "default_cores" should be moved to test_case.py. All suite shared variabl= e > should be defined there. >=20 > > -----Original Message----- > > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of huilongx xu > > Sent: Wednesday, May 20, 2015 2:32 PM > > To: dts@dpdk.org > > Subject: [dts] [dts v1] support dpdk2.0 code > > > > From: huilong xu > > > > changed list: > > 1. when start testpmd by pmd_output model, if testpmd parameter not > > include > > "--txqflags=3D0", add it. because in dpdk2.0 testpmd must used txqfl= ags > > for > > open hardware features, egg: checsum offload, vlan > > 2. dut add a function set_default_corelist, if the server cores number > > more then 4, the default cores is 4. In test case you can used > > self.dut.default_cores > > to start app. > > > > Signed-off-by: huilong xu > > --- > > framework/dut.py | 11 +++++++++++ > > framework/pmd_output.py | 3 +++ > > 2 files changed, 14 insertions(+), 0 deletions(-) > > > > diff --git a/framework/dut.py b/framework/dut.py > > index 5b7aba2..656fc78 100644 > > --- a/framework/dut.py > > +++ b/framework/dut.py > > @@ -140,6 +140,16 @@ class Dut(Crb): > > """ > > return self.crb['pass'] > > > > + def set_default_corelist(self): > > + """ > > + set default cors list > > + """ > > + core_num =3D len(self.cores) > > + if core_num <=3D 4: > > + self.default_cores =3D "1S/%dC/1T" % core_num > > + else: > > + self.default_cores =3D "1S/4C/1T" > > + > > def dut_prerequisites(self): > > """ > > Prerequest function should be called before execute any test > case. > > @@ -155,6 +165,7 @@ class Dut(Crb): > > self.send_expect('alias sed=3Dgsed', '# ') > > > > self.init_core_list() > > + self.set_default_corelist() > > self.pci_devices_information() > > # scan ports before restore interface > > self.scan_ports() > > diff --git a/framework/pmd_output.py b/framework/pmd_output.py > > index 97274a5..78b4e4f 100644 > > --- a/framework/pmd_output.py > > +++ b/framework/pmd_output.py > > @@ -87,6 +87,9 @@ class PmdOutput(): > > return self.command > > > > def start_testpmd(self, cores, param=3D'', eal_param=3D'', socket= =3D0): Better to handle special cores parameter like "ALL", "Default" here. > > + if "--txqflags" not in param: > > + param +=3D " --txqflags=3D0" > > + > > core_list =3D self.dut.get_core_list(cores, socket) > > self.coremask =3D dts.create_mask(core_list) > > command =3D "./%s/app/testpmd -c %s -n %d %s -- -i %s" \ > > -- > > 1.7.4.4