DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Cc: stable@dpdk.org, "Burakov, Anatoly" <anatoly.burakov@intel.com>,
	dev@dpdk.org, wuzhouhui250@gmail.com, pawelx.wodkowski@intel.com,
	gowrishankar.m@linux.vnet.ibm.com
Subject: Re: [dpdk-dev] [dpdk-stable] [PATCH] eal/vfio: share the default container in multi process
Date: Mon, 29 Oct 2018 01:17:47 +0100	[thread overview]
Message-ID: <2151144.DLmmOzqKvU@xps> (raw)
In-Reply-To: <45f61fc2-ee13-e342-6f4d-0178df40c94d@intel.com>

05/10/2018 10:57, Burakov, Anatoly:
> On 03-Oct-18 1:39 PM, Darek Stojaczyk wrote:
> > So far each process in MP used to have a separate container
> > and relied on the primary process to register all memsegs.
> > 
> > Mapping external memory via rte_vfio_container_dma_map()
> > in secondary processes was broken, because the default
> > (process-local) container had no groups bound. There was
> > even no way to bind any groups to it, because the container
> > fd was deeply encapsulated within EAL.
> > 
> > This patch introduces a new SOCKET_REQ_DEFAULT_CONTAINER
> > message type for MP synchronization, makes all processes
> > within a MP party use a single default container, and hence
> > fixes rte_vfio_container_dma_map() for secondary processes.
> > 
> >>From what I checked this behavior was always the same, but
> > started to be invalid/insufficient once mapping external
> > memory was allowed.
> > 
> > Fixes: 73a639085938 ("vfio: allow to map other memory regions")
> > Cc: anatoly.burakov@intel.com
> > Cc: pawelx.wodkowski@intel.com
> > Cc: gowrishankar.m@linux.vnet.ibm.com
> > Cc: stable@dpdk.org
> > 
> > While here, fix up the comment on rte_vfio_get_container_fd().
> > This function always opens a new container, never reuses
> > an old one.
> > 
> > Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
> > ---
> 
> <snip>
> 
> > +	if (internal_config.process_type == RTE_PROC_PRIMARY) {
> > +		/* if we were secondary process we would try requesting
> > +		 * container fd from the primary, but we're the primary
> > +		 * process so just exit here
> > +		 */
> > +		return -1;
> > +	}
> > +
> > +	p->req = SOCKET_REQ_DEFAULT_CONTAINER;
> > +	strcpy(mp_req.name, EAL_VFIO_MP);
> 
> strlcpy?
> 
> Otherwise,
> Reviewed-by: Anatoly Burakov <anatoly.burakov@intel.com>

Applied, thanks

      parent reply	other threads:[~2018-10-29  0:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-03 12:39 [dpdk-dev] " Darek Stojaczyk
2018-10-04 15:52 ` Burakov, Anatoly
2018-10-05  8:52   ` Burakov, Anatoly
2018-10-05  8:57 ` Burakov, Anatoly
2018-10-05 10:36   ` Stojaczyk, Dariusz
2018-10-05 12:40   ` Ferruh Yigit
2018-10-29  0:17   ` Thomas Monjalon [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=2151144.DLmmOzqKvU@xps \
    --to=thomas@monjalon.net \
    --cc=anatoly.burakov@intel.com \
    --cc=dariusz.stojaczyk@intel.com \
    --cc=dev@dpdk.org \
    --cc=gowrishankar.m@linux.vnet.ibm.com \
    --cc=pawelx.wodkowski@intel.com \
    --cc=stable@dpdk.org \
    --cc=wuzhouhui250@gmail.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).