From mboxrd@z Thu Jan 1 00:00:00 1970 From: Remy Horton Subject: Re: [PATCH v4 02/24] bus/vdev: enable one device scan Date: Tue, 26 Jun 2018 11:49:41 +0100 Message-ID: <0df711a0-34df-1510-7b5b-4488a67b1701@intel.com> References: <20180607123849.14439-1-qi.z.zhang@intel.com> <20180626070832.3055-1-qi.z.zhang@intel.com> <20180626070832.3055-3-qi.z.zhang@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: konstantin.ananyev@intel.com, dev@dpdk.org, bruce.richardson@intel.com, ferruh.yigit@intel.com, benjamin.h.shelton@intel.com, narender.vangati@intel.com To: Qi Zhang , thomas@monjalon.net, anatoly.burakov@intel.com Return-path: Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by dpdk.org (Postfix) with ESMTP id 090EE1B3AB for ; Tue, 26 Jun 2018 12:49:44 +0200 (CEST) In-Reply-To: <20180626070832.3055-3-qi.z.zhang@intel.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 26/06/2018 08:08, Qi Zhang wrote: > The patch implemented the ops scan_one for vdev bus, it gives two benifits > 1. Improve scan efficiency when a device is attached as hotplug, since no > need to pupulate a new device by iterating all devargs in devargs_list. > 2. It also avoid sync IPC invoke (which happens in vdev->scan on secondary > process). The benifit is this removes the potential deadlock in the case > when secondary process receive a request from primary process to attach a > new device, since vdev->scan will be invoked on mp thread itself in that > case. Slight rewording and spelling corrections within description: The patch implements the ops scan_one for the vdev bus, which gives two benefits: 1. Improves scan efficiency when a device is attached as hotplug, since there is no need to populate a new device by iterating all devargs in devargs_list 2. It also avoids sync IPC invoke (which happens in vdev->scan on secondary process). The benefit is this removes the potential deadlock in the case when a secondary process receives a request from primary process to attach a new device, since vdev->scan will be invoked on mp thread itself in that case. > Signed-off-by: Qi Zhang > --- > > drivers/bus/vdev/vdev.c | 30 ++++++++++++++++++++++++++++++ > 1 file changed, 30 insertions(+) Acked-by: Remy Horton