From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by dpdk.org (Postfix) with ESMTP id A94D04CB3 for ; Tue, 20 Mar 2018 18:28:22 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 2B16D20F4D; Tue, 20 Mar 2018 13:28:22 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute1.internal (MEProxy); Tue, 20 Mar 2018 13:28:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=mesmtp; bh=jocVkWiZ0P+2xylntHGX6lv8Mv Ao3Y+P0/sc226h+sI=; b=UGq5xSAoQ6MdQj5RbjthPxrJgm1NrtuzFYFzHGp0gc WPQP3NH4ZnyVF6bXx5GvOYNH+xXgXF9rPU4Oz3hzwNMvfWPXbRpV14kYbtTVwirz mKm7ZcmRsnpjf624GKuF815N15jSCuk5AIUXkzMr+qBKu9Qzv+WOK8FmMby8oe9n s= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=jocVkW iZ0P+2xylntHGX6lv8MvAo3Y+P0/sc226h+sI=; b=OkPb/yFE+VXZcYlqcCKNDV 42I/j10V0XQYxczcFvw00xNc3W984r3Cq2WqwlnYTN6ZO60Mvf2SEwUZ7S1HdwVb sTtP1Iyttreak4LWrwvbeO7/FKMeYBDmDPOEh0ZZA2ZHPkKTEk+0NFhCnuKX5dUL DrAr+fm+2eo/wvZsfSCCT+OSZsSaI7HL2I2G1Q//sjlufFY7TgP8n9pNGwwJMiQl o1TD2AuRzxxls7a+z4p4SErXQXf/rwuUpYpG3G6MISpD7EZmiWOYOoT4df5FCRCe FJ2YuRuT1hFdbQK37T2p0KV8QZhzc5wvrxur6pK4MbehDJTuyUquJ5+j9zypAgfQ == X-ME-Sender: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 70F4A24234; Tue, 20 Mar 2018 13:28:20 -0400 (EDT) From: Thomas Monjalon To: Bruce Richardson Cc: Pavan Nikhilesh , jerin.jacob@caviumnetworks.com, santosh.shukla@caviumnetworks.com, anatoly.burakov@intel.com, lironh@marvell.com, fiona.trahe@intel.com, shreyansh.jain@nxp.com, hemant.agrawal@nxp.com, dev@dpdk.org Date: Tue, 20 Mar 2018 18:27:53 +0100 Message-ID: <2404641.e51pahgxmm@xps> In-Reply-To: <20180320170120.GA4260@bricha3-MOBL.ger.corp.intel.com> References: <20180319092726.10153-1-pbhagavatula@caviumnetworks.com> <20180320160624.GB18022@ltp-pvn> <20180320170120.GA4260@bricha3-MOBL.ger.corp.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v2 1/2] drivers: add common folder X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Mar 2018 17:28:23 -0000 20/03/2018 18:01, Bruce Richardson: > On Tue, Mar 20, 2018 at 09:36:25PM +0530, Pavan Nikhilesh wrote: > > Hi Thomas, > > > > On Tue, Mar 20, 2018 at 04:45:47PM +0100, Thomas Monjalon wrote: > > > 20/03/2018 15:40, Pavan Nikhilesh: > > > > Add driver/common folder and skeleton makefile for adding commonly > > > > used functions across mempool, event and net devices. > > > > > > I am not sure there is a real benefit of introducing such new > > > directory. Is it only solving the choice of where you add files used > > > by several drivers? Is drivers/bus/X/ the directory of choice for > > > platform shared files? > > > > drivers/bus doesn't seem to be a appropriate abstraction common API's > > used across multiple PMD's. > > > > This change is in regards with the discussion on ml: > > http://dpdk.org/ml/archives/dev/2018-March/092822.html > > > > drivers/common seems to be a popular opinion but maybe we could use > > something like drivers/SoC or if you have something in mind please > > suggest. > > > I think drivers/common is a better solution as it's not just platform buses > or SoC's that this occurs with. Even PCI devices can export multiple > functions, such as in the QAT case, which leads to the case where you have > shared code between different driver classes. I don't think the PCI bus > driver is a good place to put QAT shared code. :-) If drivers X and Y share some code, it is possible to link files from X directory in Y library. If we want a more explicit and separate directory for shared code, what would be the name of the sub-directories? drivers/common/qat? drivers/common/octeontx? drivers/common/marvell? drivers/common/mellanox?