X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fperformance-thread%2Fcommon%2Flthread_mutex.c;h=c06d3d513cdb5309a068258521b023896cf6573e;hb=98a7ea332ba3da0f74ec951595d36a616165b255;hp=074d066c7df9b9cc0648eb7e6b019bff5a3a6cb6;hpb=116819b9ed0da46ba09b927a9d54795e5f56cbdc;p=dpdk.git diff --git a/examples/performance-thread/common/lthread_mutex.c b/examples/performance-thread/common/lthread_mutex.c index 074d066c7d..c06d3d513c 100644 --- a/examples/performance-thread/common/lthread_mutex.c +++ b/examples/performance-thread/common/lthread_mutex.c @@ -44,7 +44,6 @@ #include #include -#include #include #include #include @@ -171,11 +170,10 @@ int lthread_mutex_lock(struct lthread_mutex *m) _suspend(); /* resumed, must loop and compete for the lock again */ } - LTHREAD_ASSERT(0); return 0; } -/* try to lock a mutex but dont block */ +/* try to lock a mutex but don't block */ int lthread_mutex_trylock(struct lthread_mutex *m) { struct lthread *lt = THIS_LTHREAD; @@ -232,7 +230,7 @@ int lthread_mutex_unlock(struct lthread_mutex *m) if (unblocked != NULL) { rte_atomic64_dec(&m->count); DIAG_EVENT(m, LT_DIAG_MUTEX_UNLOCKED, m, unblocked); - LTHREAD_ASSERT(unblocked->sched != NULL); + RTE_ASSERT(unblocked->sched != NULL); _ready_queue_insert((struct lthread_sched *) unblocked->sched, unblocked); break;