DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: Bruce Richardson <bruce.richardson@intel.com>,
	dev@dpdk.org, stable@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] pci: fix missing pci bus with shared library build
Date: Mon, 22 Jul 2019 19:04:55 +0200	[thread overview]
Message-ID: <3107061.JzsCpgzbfO@xps> (raw)
In-Reply-To: <20190722094323.613cb090@xps13>

22/07/2019 18:43, Stephen Hemminger:
> On Mon, 22 Jul 2019 10:06:11 +0100
> Bruce Richardson <bruce.richardson@intel.com> wrote:
> > On Mon, Jul 22, 2019 at 09:38:27AM +0200, Thomas Monjalon wrote:
> > > 19/07/2019 22:55, Stephen Hemminger:  
> > > > The root cause is that recent gcc won't run constructor on unused libraries.
> > > > Testing a patch to take --as-needed off of PCI library.
> > > > 
> > > > See: https://stackoverflow.com/questions/11631161/force-to-link-against-unused-shared-library  
> > > 
> > > The constructor is run when calling dlopen, right?
> > > 
> > > Note: dlopen with -d is a feature.
> > > The original idea was to be able to specify which driver we want to use.
> > > If we want an automatic dlopen, like modprobe, then we need more scripts.
> > > But I understand you are against the whole dlopen idea.
> > 
> > This issue is more of a problem for development systems where we EAL path
> > is not really usable for finding the drivers. For a properly deployed
> > system where we use DPDK installed to /usr/local or /usr, the EAL PMD path
> > will be correctly configured and properly probe all drivers.
> 
> The problem is that bus drivers register themselves in constructors and
> these construtors are not run with as-needed.

Are the constructors run on dlopen of the bus driver?




  reply	other threads:[~2019-07-22 17:05 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-15 23:41 Stephen Hemminger
2019-07-16  0:16 ` Stephen Hemminger
2019-07-16  0:19 ` Stephen Hemminger
2019-07-16  8:46   ` Bruce Richardson
2019-07-16 14:46     ` Stephen Hemminger
2019-07-19 18:11     ` Stephen Hemminger
2019-07-19 20:39     ` Stephen Hemminger
2019-07-19 20:55     ` Stephen Hemminger
2019-07-22  7:38       ` Thomas Monjalon
2019-07-22  9:06         ` Bruce Richardson
2019-07-22 16:43           ` Stephen Hemminger
2019-07-22 17:04             ` Thomas Monjalon [this message]
2019-07-22 17:13               ` Stephen Hemminger
2019-07-22 17:31                 ` Thomas Monjalon
2019-07-22 18:34                   ` Stephen Hemminger
2019-07-23  7:59                     ` Thomas Monjalon
2019-07-23 18:29                       ` Stephen Hemminger
2019-07-23 18:35                         ` Thomas Monjalon
2019-07-22 18:53                   ` Stephen Hemminger
2019-07-23 12:30                     ` Bruce Richardson
2019-07-23 18:11                       ` Stephen Hemminger
2019-07-24  8:56                         ` Bruce Richardson
2019-07-23 18:47                       ` Stephen Hemminger

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=3107061.JzsCpgzbfO@xps \
    --to=thomas@monjalon.net \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=stable@dpdk.org \
    --cc=stephen@networkplumber.org \
    /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).