From db0b7ae0626ebdfc3cda7bef8bd7bad343cead23 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Thu, 12 Mar 2015 09:28:03 +0000 Subject: More MISRA. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7760 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/osal/nil/osal.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'os/hal/osal/nil/osal.c') diff --git a/os/hal/osal/nil/osal.c b/os/hal/osal/nil/osal.c index b595f1ca1..92c350492 100644 --- a/os/hal/osal/nil/osal.c +++ b/os/hal/osal/nil/osal.c @@ -62,7 +62,7 @@ void osalThreadDequeueNextI(threads_queue_t *tqp, msg_t msg) { semaphore_t *sp = &tqp->sem; - if (chSemGetCounterI(&tqp->sem) < 0) { + if (chSemGetCounterI(&tqp->sem) < (cnt_t)0) { thread_reference_t tr = nil.threads; while (true) { /* Is this thread waiting on this semaphore?*/ @@ -71,7 +71,7 @@ void osalThreadDequeueNextI(threads_queue_t *tqp, msg_t msg) { chDbgAssert(NIL_THD_IS_WTSEM(tr), "not waiting"); - chSchReadyI(tr, msg); + (void) chSchReadyI(tr, msg); return; } tr++; @@ -96,16 +96,16 @@ void osalThreadDequeueAllI(threads_queue_t *tqp, msg_t msg) { cnt_t cnt; cnt = sp->cnt; - sp->cnt = 0; + sp->cnt = (cnt_t)0; tr = nil.threads; - while (cnt < 0) { + while (cnt < (cnt_t)0) { /* Is this thread waiting on this semaphore?*/ if (tr->u1.semp == sp) { chDbgAssert(NIL_THD_IS_WTSEM(tr), "not waiting"); cnt++; - chSchReadyI(tr, msg); + (void) chSchReadyI(tr, msg); } tr++; -- cgit v1.2.3