From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] eal: change init macro as exec environment specific Date: Tue, 02 Apr 2019 14:57:03 +0200 Message-ID: <1935282.F1JuZfYupj@xps> References: <20170807120408.21975-1-jerin.jacob@caviumnetworks.com> <30782747.pV0nTTKWH9@xps> <20171011143352.GA23500@jerin> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org, bruce.richardson@intel.com, anand.rawat@intel.com, ranjit.menon@intel.com, ferruh.yigit@intel.com, david.marchand@redhat.com To: Jerin Jacob Return-path: Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by dpdk.org (Postfix) with ESMTP id A0EB12B99 for ; Tue, 2 Apr 2019 14:57:07 +0200 (CEST) In-Reply-To: <20171011143352.GA23500@jerin> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 11/10/2017 16:33, Jerin Jacob: > From: Thomas Monjalon > > 07/08/2017 14:04, Jerin Jacob: > > > baremetal execution environments may have a different > > > method to enable RTE_INIT instead of using compiler > > > constructor scheme. Move RTE_INIT* definition under > > > exec-env to support different execution environments. > > > > > > Signed-off-by: Jerin Jacob > > > --- > > > app/test-eventdev/evt_test.h | 2 +- > > > lib/librte_eal/bsdapp/eal/Makefile | 2 +- > > > .../bsdapp/eal/include/exec-env/rte_eal.h | 51 ++++++++++++++++++++++ I sent a patch to flatten the hierarchy, removing exec-env. And I'm not sure about the file name rte_eal.h. Please could you move it to lib/librte_eal//eal/include/rte_exec_env.h or another better name? Note that Windows is introducing rte_os.h. PS: I'm not sure about the intent of rte_os.h. Should it be rte_libc.h? > > > lib/librte_eal/common/eal_common_log.c | 2 + > > > lib/librte_eal/common/include/rte_bus.h | 2 + > > > lib/librte_eal/common/include/rte_eal.h | 6 --- > > > lib/librte_eal/common/include/rte_tailq.h | 2 + > > > lib/librte_eal/linuxapp/eal/Makefile | 2 +- > > > .../linuxapp/eal/include/exec-env/rte_eal.h | 51 ++++++++++++++++++++++ > > > > I am not a big fan of duplicating code for Linux and BSD. > > > > Maybe we should have different splits and include a common file > > in Linux and BSD? > > OK. This is doable. After some thoughts about Windows port, I think we need to consider a better split. The constructors are the same for Linux, BSD and Windows, isn't it? Is it related to splitting between POSIX libc and others?