]> git.droids-corp.org - dpdk.git/commitdiff
sleep in control plane thread delay
authorOlivier Matz <olivier.matz@6wind.com>
Fri, 27 Mar 2020 15:34:53 +0000 (16:34 +0100)
committerOlivier Matz <olivier.matz@6wind.com>
Fri, 27 Mar 2020 15:37:44 +0000 (16:37 +0100)
lib/librte_eal/common/include/generic/rte_cycles.h

index 73d1fa7b923d5d172cfca71bab54474c7ff7c8f9..a770562578949c6d72b50282c4d2238e31e198cc 100644 (file)
@@ -147,7 +147,10 @@ extern void
 static inline void
 rte_delay_ms(unsigned ms)
 {
-       rte_delay_us(ms * 1000);
+       if (rte_lcore_id() == LCORE_ID_ANY)
+               usleep(ms * 1000);
+       else
+               rte_delay_us(ms * 1000);
 }
 
 /**