DPDK patches and discussions
 help / color / mirror / Atom feed
From: "De Lara Guarch, Pablo" <pablo.de.lara.guarch@intel.com>
To: "De Lara Guarch, Pablo" <pablo.de.lara.guarch@intel.com>,
	Thomas Monjalon <thomas.monjalon@6wind.com>,
	"Yigit, Ferruh" <ferruh.yigit@intel.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	"Mcnamara, John" <john.mcnamara@intel.com>
Subject: Re: [dpdk-dev] [PATCH] doc: announce API change for virtual device initialization
Date: Wed, 6 Jul 2016 10:59:05 +0000	[thread overview]
Message-ID: <E115CCD9D858EF4F90C690B0DCB4D8973C989533@IRSMSX108.ger.corp.intel.com> (raw)
In-Reply-To: <E115CCD9D858EF4F90C690B0DCB4D8973C988EF2@IRSMSX108.ger.corp.intel.com>



> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of De Lara Guarch,
> Pablo
> Sent: Tuesday, July 05, 2016 3:55 PM
> To: Thomas Monjalon; Yigit, Ferruh
> Cc: dev@dpdk.org; Mcnamara, John
> Subject: Re: [dpdk-dev] [PATCH] doc: announce API change for virtual device
> initialization
> 
> 
> 
> > -----Original Message-----
> > From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]
> > Sent: Tuesday, July 05, 2016 2:39 PM
> > To: Yigit, Ferruh
> > Cc: dev@dpdk.org; De Lara Guarch, Pablo; Mcnamara, John
> > Subject: Re: [dpdk-dev] [PATCH] doc: announce API change for virtual device
> > initialization
> >
> > 2016-07-05 14:04, Ferruh Yigit:
> > > On 7/4/2016 3:50 PM, Pablo de Lara wrote:
> > > > +* The rte_eal_vdev_init function will be changed in 16.11 to return
> > > > +  the port/device id of the device created, instead of 0, when it has
> been
> > > > +  initialized successfully, so user can use the returned value straight
> away
> > > > +  to call all the device functions that require that parameter.
> > >
> > > There is another API rte_eth_dev_attach(), which returns port_id, and is
> > > a common wrapper both for pdev and vdev.
> > > So with proper devargs this API calls rte_eal_vdev_init() and returns
> > > port_id (set in argument) without any extra side effect.
> >
> > I think rte_eth_dev_attach() should be removed from ethdev.
> > Hotplugging a device belongs to device management, i.e. EAL.
> 
> Even though rte_eth_dev_attach returns the port id, I think that
> rte_eal_vdev_init
> can return the port id anyway (and then, we can remove the call to
> rte_eth_dev_get_port_by_name
>  in rte_eth_dev_attach).

Also, that function is only applicable to Ethernet devices,
so other devices like Crypto devices cannot be used.
If we want to use that function for all devices, we should move it to eal,
modify it slightly and rename it, and therefore, we will need
a deprecation notice as well.

  reply	other threads:[~2016-07-06 10:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-04 14:50 Pablo de Lara
2016-07-05 10:44 ` Declan Doherty
2016-07-05 13:04 ` Ferruh Yigit
2016-07-05 13:38   ` Thomas Monjalon
2016-07-05 14:55     ` De Lara Guarch, Pablo
2016-07-06 10:59       ` De Lara Guarch, Pablo [this message]
2016-07-28 12:18 ` David Marchand
2016-07-28 15:47   ` De Lara Guarch, Pablo
2016-07-28 15:56     ` David Marchand
2016-07-29 17:35     ` Andriy Berestovskyy

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=E115CCD9D858EF4F90C690B0DCB4D8973C989533@IRSMSX108.ger.corp.intel.com \
    --to=pablo.de.lara.guarch@intel.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=john.mcnamara@intel.com \
    --cc=thomas.monjalon@6wind.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).