test suite reviews and discussions
 help / color / mirror / Atom feed
From: "Tu, Lijuan" <lijuan.tu@intel.com>
To: "Mo, YufengX" <yufengx.mo@intel.com>,
	"dts@dpdk.org" <dts@dpdk.org>,
	"Ma,  LihongX" <lihongx.ma@intel.com>,
	"Chen, Zhaoyan" <zhaoyan.chen@intel.com>
Cc: "Mo, YufengX" <yufengx.mo@intel.com>
Subject: Re: [dts] [PATCH V1 1/1] framework/pktgen: add tester port mapping
Date: Tue, 25 Feb 2020 09:07:43 +0000	[thread overview]
Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BBCE003@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <20200225074307.17136-2-yufengx.mo@intel.com>

Applied, thanks

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of yufengmx
> Sent: Tuesday, February 25, 2020 3:43 PM
> To: dts@dpdk.org; Ma, LihongX <lihongx.ma@intel.com>; Chen, Zhaoyan
> <zhaoyan.chen@intel.com>
> Cc: Mo, YufengX <yufengx.mo@intel.com>
> Subject: [dts] [PATCH V1 1/1] framework/pktgen: add tester port mapping
> 
> 
> Since tester port scanning work flow change, non-functional port mapping
> config will be ignored.
> Add tester port mapping if no port in ports info.
> 
> Signed-off-by: yufengmx <yufengx.mo@intel.com>
> ---
>  framework/tester.py | 17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
> 
> diff --git a/framework/tester.py b/framework/tester.py index
> a858081..6e92847 100644
> --- a/framework/tester.py
> +++ b/framework/tester.py
> @@ -366,6 +366,7 @@ class Tester(Crb):
>          ''' packet generator port setting
>          Currently, trex run on tester node
>          '''
> +        new_ports_info = []
>          pktgen_ports_info = self.pktgen.get_ports()
>          for pktgen_port_info in pktgen_ports_info:
>              pktgen_port_type = pktgen_port_info['type'] @@ -383,6 +384,22 @@
> class Tester(Crb):
>                  port_info['type'] = pktgen_port_type
>                  port_info['mac'] = pktgen_mac
>                  break
> +            # Since tester port scanning work flow change, non-functional port
> +            # mapping config will be ignored. Add tester port mapping if no
> +            # port in ports info
> +            else:
> +                addr_array = pktgen_pci.split(':')
> +                port = GetNicObj(self, addr_array[0], addr_array[1], addr_array[2])
> +                new_ports_info.append({
> +                    'port': port,
> +                    'intf': pktgen_port_name,
> +                    'type': pktgen_port_type,
> +                    'pci': pktgen_pci,
> +                    'mac': pktgen_mac,
> +                    'ipv4': None,
> +                    'ipv6': None })
> +        if new_ports_info:
> +            self.ports_info = self.ports_info + new_ports_info
> 
>      def scan_ports(self):
>          """
> --
> 2.21.0


      reply	other threads:[~2020-02-25  9:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-25  7:43 [dts] [PATCH V1 0/1] " yufengmx
2020-02-25  7:43 ` [dts] [PATCH V1 1/1] " yufengmx
2020-02-25  9:07   ` Tu, Lijuan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8CE3E05A3F976642AAB0F4675D0AD20E0BBCE003@SHSMSX101.ccr.corp.intel.com \
    --to=lijuan.tu@intel.com \
    --cc=dts@dpdk.org \
    --cc=lihongx.ma@intel.com \
    --cc=yufengx.mo@intel.com \
    --cc=zhaoyan.chen@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).