]> git.droids-corp.org - dpdk.git/commitdiff
timer: add a rte_pause in a tight loop
authorIntel <intel.com>
Mon, 3 Jun 2013 00:00:00 +0000 (00:00 +0000)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Tue, 17 Sep 2013 12:09:22 +0000 (14:09 +0200)
Signed-off-by: Intel
lib/librte_timer/rte_timer.c

index 136b641e37949a5d522600481d37c89dd8ebc002..f3798aebc530e782b4c6adbb54d47f7b1848beeb 100644 (file)
@@ -387,7 +387,8 @@ rte_timer_stop(struct rte_timer *tim)
 void
 rte_timer_stop_sync(struct rte_timer *tim)
 {
-       while (rte_timer_stop(tim) != 0);
+       while (rte_timer_stop(tim) != 0)
+               rte_pause();
 }
 
 /* Test the PENDING status of the timer handle tim */