[dpdk-dev] [PATCH 03/19] eal: dlopen the DSO built poll mode drivers before init
Neil Horman
nhorman at tuxdriver.com
Thu Apr 10 22:49:53 CEST 2014
We need to call dlopen on any DSO's referenced on the command line before
calling their init routines. This provides the DSO's the opportunity to run the
constructors created by the PMD_INIT_NONPCI macro prior to the init list being
traversed.
Signed-off-by: Neil Horman <nhorman at tuxdriver.com>
---
lib/librte_eal/linuxapp/eal/eal.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/librte_eal/linuxapp/eal/eal.c b/lib/librte_eal/linuxapp/eal/eal.c
index 905ce37..a4ad0eb 100644
--- a/lib/librte_eal/linuxapp/eal/eal.c
+++ b/lib/librte_eal/linuxapp/eal/eal.c
@@ -1046,9 +1046,6 @@ rte_eal_init(int argc, char **argv)
rte_eal_mcfg_complete();
- if (rte_eal_non_pci_ethdev_init() < 0)
- rte_panic("Cannot init non-PCI eth_devs\n");
-
TAILQ_FOREACH(solib, &solib_list, next) {
solib->lib_handle = dlopen(solib->name, RTLD_NOW);
if ((solib->lib_handle == NULL) && (solib->name[0] != '/')) {
@@ -1061,6 +1058,9 @@ rte_eal_init(int argc, char **argv)
RTE_LOG(WARNING, EAL, "%s\n", dlerror());
}
+ if (rte_eal_non_pci_ethdev_init() < 0)
+ rte_panic("Cannot init non-PCI eth_devs\n");
+
RTE_LOG(DEBUG, EAL, "Master core %u is ready (tid=%x)\n",
rte_config.master_lcore, (int)thread_id);
--
1.8.3.1
More information about the dev
mailing list