From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] doc: announce API change for virtual device initialization Date: Tue, 05 Jul 2016 15:38:33 +0200 Message-ID: <2208144.gyRL4FDPKl@xps13> References: <1467643848-14780-1-git-send-email-pablo.de.lara.guarch@intel.com> <577BB05B.3070203@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org, Pablo de Lara , john.mcnamara@intel.com To: Ferruh Yigit Return-path: Received: from mail-wm0-f49.google.com (mail-wm0-f49.google.com [74.125.82.49]) by dpdk.org (Postfix) with ESMTP id BF5665955 for ; Tue, 5 Jul 2016 15:38:35 +0200 (CEST) Received: by mail-wm0-f49.google.com with SMTP id z126so76017168wme.0 for ; Tue, 05 Jul 2016 06:38:35 -0700 (PDT) In-Reply-To: <577BB05B.3070203@intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 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.