DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Phil Yang (Arm Technology China)" <Phil.Yang@arm.com>
To: "Ananyev, Konstantin" <konstantin.ananyev@intel.com>,
	dev <dev-bounces@dpdk.org>, "dev@dpdk.org" <dev@dpdk.org>
Cc: "Yigit, Ferruh" <ferruh.yigit@intel.com>, nd <nd@arm.com>
Subject: Re: [dpdk-dev] [PATCH] app/testpmd: fix physic port	socket	initialization
Date: Wed, 17 Oct 2018 01:41:01 +0000	[thread overview]
Message-ID: <DB7PR08MB3385D0CA51E70D9C1109421AE9FF0@DB7PR08MB3385.eurprd08.prod.outlook.com> (raw)
In-Reply-To: <2601191342CEEE43887BDE71AB9772580102FE779C@IRSMSX106.ger.corp.intel.com>

> -----Original Message-----
> From: dev <dev-bounces@dpdk.org> On Behalf Of Ananyev, Konstantin
> Sent: Tuesday, October 16, 2018 6:40 PM
> To: dev <dev-bounces@dpdk.org>; dev@dpdk.org
> Cc: Yigit, Ferruh <ferruh.yigit@intel.com>; nd <nd@arm.com>
> Subject: Re: [dpdk-dev] [PATCH] app/testpmd: fix physic port socket initialization
> 
> 
> 
> > -----Original Message-----
> > From: dev [mailto:dev-bounces@dpdk.org]
> > Sent: Tuesday, October 16, 2018 11:15 AM
> > To: dev@dpdk.org
> > Cc: Yigit, Ferruh <ferruh.yigit@intel.com>; nd@arm.com
> > Subject: [dpdk-dev] [PATCH] app/testpmd: fix physic port socket
> > initialization
> >
> > Once the lcore list setting excluded the socket which physic device
> > attached, it will cause failure. Meanwhile, it will disable Testpmd
> > cross NUMA scenario.
> >
> > Fixes: dbfb8ec ("app/testpmd: optimize mbuf pool allocation")
> >
> > Signed-off-by: Phil Yang <phil.yang@arm.com>
> > Reviewed-by: Gavin Hu <Gavin.Hu@arm.com>
> > ---
> >  app/test-pmd/testpmd.c | 14 +++++++++++++-
> >  1 file changed, 13 insertions(+), 1 deletion(-)
> >
> > diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index
> > 5dbbf78..4739ddb 100644
> > --- a/app/test-pmd/testpmd.c
> > +++ b/app/test-pmd/testpmd.c
> > @@ -565,9 +565,21 @@ set_default_fwd_ports_config(void)
> >  	portid_t pt_id;
> >  	int i = 0;
> >
> > -	RTE_ETH_FOREACH_DEV(pt_id)
> > +	RTE_ETH_FOREACH_DEV(pt_id) {
> >  		fwd_ports_ids[i++] = pt_id;
> >
> > +		/* Update sockets info according to the attached device */
> > +		int socket_id = rte_eth_dev_socket_id(pt_id);
> > +		if (socket_id >= 0 && new_socket_id(pt_id)) {
> 
> Should be: ' new_socket_id(socket_id)', I think.
> Konstantin

Exactly.
Thanks Konstantin. It has been fixed in V2.

> 
> > +			if (num_sockets >= RTE_MAX_NUMA_NODES) {
> > +				rte_exit(EXIT_FAILURE,
> > +					 "Total sockets greater than %u\n",
> > +					 RTE_MAX_NUMA_NODES);
> > +			}
> > +			socket_ids[num_sockets++] = socket_id;
> > +		}
> > +	}
> > +
> >  	nb_cfg_ports = nb_ports;
> >  	nb_fwd_ports = nb_ports;
> >  }
> > --
> > 2.7.4

  reply	other threads:[~2018-10-17  1:41 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-16 10:14 Phil Yang
2018-10-16 10:40 ` Ananyev, Konstantin
2018-10-17  1:41   ` Phil Yang (Arm Technology China) [this message]
2018-10-17  1:36 ` [dpdk-dev] [PATCH v2] " Phil Yang
2018-10-17 11:02   ` Ananyev, Konstantin
2018-10-17 13:04     ` Ferruh Yigit
2018-10-18  2:37       ` Phil Yang (Arm Technology China)

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=DB7PR08MB3385D0CA51E70D9C1109421AE9FF0@DB7PR08MB3385.eurprd08.prod.outlook.com \
    --to=phil.yang@arm.com \
    --cc=dev-bounces@dpdk.org \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=konstantin.ananyev@intel.com \
    --cc=nd@arm.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).