DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Wiles, Keith" <keith.wiles@intel.com>
To: Thomas Monjalon <thomas.monjalon@6wind.com>,
	Don Provan <dprovan@bivio.net>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] rte_eal_init() alternative?
Date: Wed, 2 Sep 2015 22:01:54 +0000	[thread overview]
Message-ID: <D20CD6FA.29AEF%keith.wiles@intel.com> (raw)
In-Reply-To: <1964148.0REVA6fuqc@xps13>

On 9/2/15, 4:08 PM, "dev on behalf of Thomas Monjalon"
<dev-bounces@dpdk.org on behalf of thomas.monjalon@6wind.com> wrote:

>2015-09-02 12:00, Stephen Hemminger:
>> On Wed, 2 Sep 2015 18:17:40 +0000
>> Don Provan <dprovan@bivio.net> 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.

+1
I was also asked at one point, at DPDK summit was, if a structure based
init routine would be better for applications. Instead of passing in
command line argvs he wanted to setup a structure in his application to be
passed into a new API. The old argvs rte_eal_init() would setup a
structure and call into the new rte_eal_struct_init() routine (I guess).

I could see the new API would return ERROR (plus errno) to the application
if called directly or return ERROR to rte_eal_init() to be handle from the
command line.

That stated I am not a big fan of huge structures being passed into a init
routine as that structure would need to be versioned and it will
grow/change. Plus he did not really want to deal in strings, so the
structure would be binary values and strings as required.

He also wanted DPDK to be more dynamic, meaning some of the values we have
in the config files should be more dynamic set via the structure and
possible have APIs to enable/disable or set the values. Each config option
would have to be looked at IMO, as some are not very easy to be dynamic
and maybe not reasonable at all.

I believe looking at the current problem of not doing a exit/panic is the
first step, next step, if everyone wants, is to look at how to initialize
DPDK from an application perspective as compared to a command line one.

>
>> 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"
>> 
>
>
>


‹ 
Regards,
++Keith
Intel Corporation

  reply	other threads:[~2015-09-02 22:02 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-02 12:49 Montorsi, Francesco
2015-09-02 12:56 ` Bruce Richardson
2015-09-02 13:10   ` Thomas Monjalon
2015-09-02 18:17     ` Don Provan
2015-09-02 19:00       ` Stephen Hemminger
2015-09-02 20:50         ` Marc Sune
2015-09-02 21:08         ` Thomas Monjalon
2015-09-02 22:01           ` Wiles, Keith [this message]
2015-09-08 18:01             ` Don Provan
2015-09-11 17:15               ` Wiles, Keith
2015-10-08 14:58     ` Montorsi, Francesco
2015-10-09  8:25       ` Panu Matilainen
2015-10-09 10:03         ` Montorsi, Francesco
2015-10-09 10:13           ` Montorsi, Francesco
2015-10-09 11:12             ` Panu Matilainen
2015-10-09 10:40           ` Panu Matilainen
2015-10-09 16:03             ` Thomas F Herbert
2015-09-02 14:08   ` Jay Rolette
2015-09-02 19:23     ` Zoltan Kiss

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=D20CD6FA.29AEF%keith.wiles@intel.com \
    --to=keith.wiles@intel.com \
    --cc=dev@dpdk.org \
    --cc=dprovan@bivio.net \
    --cc=thomas.monjalon@6wind.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).