eal/bsd: standardize init sequence between linux and bsd
authorCunming Liang <cunming.liang@intel.com>
Tue, 17 Feb 2015 02:08:05 +0000 (10:08 +0800)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Tue, 24 Feb 2015 19:20:52 +0000 (20:20 +0100)
Signed-off-by: Cunming Liang <cunming.liang@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
lib/librte_eal/bsdapp/eal/eal.c

index ca2f445..288db57 100644 (file)
@@ -514,6 +514,8 @@ rte_eal_init(int argc, char **argv)
 
        rte_eal_mcfg_complete();
 
+       eal_thread_init_master(rte_config.master_lcore);
+
        if (rte_eal_dev_init() < 0)
                rte_panic("Cannot init pmd devices\n");
 
@@ -537,8 +539,6 @@ rte_eal_init(int argc, char **argv)
                        rte_panic("Cannot create thread\n");
        }
 
-       eal_thread_init_master(rte_config.master_lcore);
-
        /*
         * Launch a dummy function on all slave lcores, so that master lcore
         * knows they are all ready when this function returns.