From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: Calling rte_eal_init multiple times in the same process Date: Thu, 17 Apr 2014 11:44:40 +0200 Message-ID: <2816958.o6HntAG0VO@xps13> References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: Tomas Vestelind Return-path: In-Reply-To: List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" Hello, 2014-04-17 09:09, Tomas Vestelind: > The problem I'm facing is that I need to do rte_eal_init serveral times in > the same process. The reason for this is mostly architectural as we want to > divide certain functionality in to different, implementation independent, > modules in which DPDK would be used for different purposes. Thus we would > need to eventually call rte_eal_init several times because we can't say for > sure if it has been called by another module or not. > > While thinking about it I saw no good, existing solution to this (I might > have missed it though). Would returning a "DPDK has already been > initialized" error code in rte_eal_init be a good way to go about it? I > haven't done this yet but I could probably provide a patch if it's > interesting. Don't hesitate to submit a patch. It's far easier to discuss on a patch basis. If your patch fill your need and nobody complains about it, it will be accepted. -- Thomas