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 257FDA04F1; Mon, 6 Jan 2020 09:57:46 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0DBE01D5FE; Mon, 6 Jan 2020 09:57:46 +0100 (CET) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id BDBB21D5FD for ; Mon, 6 Jan 2020 09:57:44 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 06 Jan 2020 00:57:43 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,401,1571727600"; d="scan'208";a="422065431" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by fmsmga006.fm.intel.com with ESMTP; 06 Jan 2020 00:57:43 -0800 Received: from fmsmsx609.amr.corp.intel.com (10.18.126.89) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 6 Jan 2020 00:57:43 -0800 Received: from fmsmsx609.amr.corp.intel.com (10.18.126.89) by fmsmsx609.amr.corp.intel.com (10.18.126.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Mon, 6 Jan 2020 00:57:43 -0800 Received: from shsmsx102.ccr.corp.intel.com (10.239.4.154) by fmsmsx609.amr.corp.intel.com (10.18.126.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.1713.5 via Frontend Transport; Mon, 6 Jan 2020 00:57:42 -0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.30]) by shsmsx102.ccr.corp.intel.com ([169.254.2.202]) with mapi id 14.03.0439.000; Mon, 6 Jan 2020 16:57:41 +0800 From: "Tu, Lijuan" To: "Ma, LihongX" , "dts@dpdk.org" CC: "Ma, LihongX" Thread-Topic: [dts] [PATCH V1] framework/pktgen_trex: set core_mask length same with ports list length Thread-Index: AQHVxGzlWqxQ/d8iWkGYzvibb3GGQKfdVdRA Date: Mon, 6 Jan 2020 08:57:41 +0000 Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BBA24C8@SHSMSX101.ccr.corp.intel.com> References: <1578273166-16197-1-git-send-email-lihongx.ma@intel.com> In-Reply-To: <1578273166-16197-1-git-send-email-lihongx.ma@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action 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/pktgen_trex: set core_mask length same with ports list length 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" applied > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of lihong > Sent: Monday, January 6, 2020 9:13 AM > To: dts@dpdk.org > Cc: Ma, LihongX > Subject: [dts] [PATCH V1] framework/pktgen_trex: set core_mask length > same with ports list length >=20 > Signed-off-by: lihong > --- > framework/pktgen_trex.py | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) >=20 > diff --git a/framework/pktgen_trex.py b/framework/pktgen_trex.py index > 2ff5894..705d8f5 100644 > --- a/framework/pktgen_trex.py > +++ b/framework/pktgen_trex.py > @@ -793,11 +793,13 @@ class TrexPacketGenerator(PacketGenerator): > try: > # clear the stats before injecting > self._conn.clear_stats() > + # 'core_mask' list must be the same length as 'ports' list > + core_mask =3D self.core_mask[:len(self._traffic_ports)] > # Start traffic on port(s) > run_opt =3D { > 'ports': self._traffic_ports, > 'mult': rate_percent, > - 'core_mask': self.core_mask, > + 'core_mask': core_mask, > 'force': True,} > self.logger.info("begin traffic ......") > self.logger.debug(run_opt) > -- > 2.7.4