From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-f180.google.com (mail-wi0-f180.google.com [209.85.212.180]) by dpdk.org (Postfix) with ESMTP id 18D6B568F for ; Wed, 2 Sep 2015 23:09:59 +0200 (CEST) Received: by wicfx3 with SMTP id fx3so30422143wic.1 for ; Wed, 02 Sep 2015 14:09:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding:content-type; bh=V5rUcozPl0AGTpeUoz/o1n3Cm/EKkqc4YgypDJOE4dM=; b=GRAsDt3EtUfMELQfl6/SyBzQUpbB0ovaT9D8xO3uSxx1aHsE3Y1kU6kNMVWtvzShzc 4xAIdYm7dHdFltov/yFuLURgzz2NOZV+klispaerQNIydSor+dUotA53FN0CV7REdOw+ SdenqvUguWkEqxu/8m7jY95Dpwqq+5Fli/S3rgcgvu5L7VPEqMOGp5j20pxWDugm6jIe cs4HfRNbsiqjkux3JQsUKBCFYQ6uURI1JEm0o7tfu7AGRCKzShJf9JWd2sySBs8/z1QP pdZ5KawCoTNCq0I8GnTOLb2dHCnhPPD/tZLn6iNWEmigFMY/IHVKbyS5IunOTDe2bH+9 VWRA== X-Gm-Message-State: ALoCoQkFuNTaOEEPhQnsXcQ4cTfsyADC5R2BmicwHoUEXTp0WRLBipDA0Aqais+v+Yo3bMd6gd7o X-Received: by 10.180.99.232 with SMTP id et8mr7015510wib.80.1441228198799; Wed, 02 Sep 2015 14:09:58 -0700 (PDT) Received: from xps13.localnet (136-92-190-109.dsl.ovh.fr. [109.190.92.136]) by smtp.gmail.com with ESMTPSA id jr5sm34276301wjc.14.2015.09.02.14.09.57 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Sep 2015 14:09:58 -0700 (PDT) From: Thomas Monjalon To: Don Provan Date: Wed, 02 Sep 2015 23:08:48 +0200 Message-ID: <1964148.0REVA6fuqc@xps13> Organization: 6WIND User-Agent: KMail/4.14.10 (Linux/4.1.6-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <20150902120039.69e3809c@urahara> References: <44e664970fef4bff942eaee5c7eaca67@bilemail1.empirix.com> <20150902120039.69e3809c@urahara> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org Subject: Re: [dpdk-dev] rte_eal_init() alternative? X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Sep 2015 21:09:59 -0000 2015-09-02 12:00, Stephen Hemminger: > On Wed, 2 Sep 2015 18:17:40 +0000 > Don Provan wrote: > > > Thomas Monjalon: > > >Yes but please, do not create an alternative init function. > > >We just need to replace panic/exit with error codes and be sure that apps and examples handle them correctly. > > > > I understand your concerns, but the panics are really just the tip of the iceberg of the EAL library not realizing it's a library. It really makes no sense to think the library should define the application's command line, or that the PCI bus should be probed without considering whether this application is going to use PCI, and or to insist that EAL work be done on internal EAL threads. > > > > So I'd say it's way past time to consider revamping initialization to start the process of ending the DPDK library's tail wagging the application's dog. Naturally this would have to be done while retaining the existing init routine on top of a real library initialization, but that's just an unfortunate artifact of the library's history, not a rational design decision for moving forward. > > > > -don provan > > > > You are welcome to submit patches with what you are proposing for review. > Theoretical requirements discussions will probably only result in more mail, > not new code. You know what you want, propose a solution. +1 Everybody agree that DPDK should be more flexible. We move from a bare metal framework to a real library. They are shortcuts in original design which can be changed. > As far as the command line. That is easily managed by realizing the application > doesn't have to pass the original command line into EAL. If you just view the > command line as a way to pass unstructured options; the application or infrastructure > can build up new values and pass it in. > > I agree that initialization itself should try and not fail except in the > most extreme cases. "ie I can't find /sys what is wrong" and should try > and adapt more "you asked for 128 cpu's but I see only 2, log it and continue" >