aboutsummaryrefslogtreecommitdiffstats
path: root/src/chsem.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/chsem.c')
-rw-r--r--src/chsem.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/chsem.c b/src/chsem.c
index d1199f072..b5c197b6b 100644
--- a/src/chsem.c
+++ b/src/chsem.c
@@ -72,7 +72,7 @@ void chSemResetI(Semaphore *sp, cnt_t n) {
cnt = sp->s_cnt;
sp->s_cnt = n;
while (cnt++ < 0)
- chSchReadyI(fifo_remove(&sp->s_queue))->p_rdymsg = RDY_RESET;
+ chSchReadyI(lifo_remove(&sp->s_queue))->p_rdymsg = RDY_RESET;
}
/**
@@ -101,7 +101,7 @@ msg_t chSemWait(Semaphore *sp) {
msg_t chSemWaitS(Semaphore *sp) {
if (--sp->s_cnt < 0) {
- fifo_insert(currp, &sp->s_queue);
+ queue_insert(currp, &sp->s_queue);
currp->p_wtsemp = sp;
chSchGoSleepS(PRWTSEM);
return currp->p_rdymsg;
@@ -140,7 +140,7 @@ msg_t chSemWaitTimeout(Semaphore *sp, systime_t time) {
msg_t chSemWaitTimeoutS(Semaphore *sp, systime_t time) {
if (--sp->s_cnt < 0) {
- fifo_insert(currp, &sp->s_queue);
+ queue_insert(currp, &sp->s_queue);
currp->p_wtsemp = sp;
return chSchGoSleepTimeoutS(PRWTSEM, time);
}
@@ -201,7 +201,7 @@ msg_t chSemSignalWait(Semaphore *sps, Semaphore *spw) {
chSchReadyI(fifo_remove(&sps->s_queue))->p_rdymsg = RDY_OK;
if (--spw->s_cnt < 0) {
- fifo_insert(currp, &spw->s_queue);
+ queue_insert(currp, &spw->s_queue);
currp->p_wtsemp = spw;
chSchGoSleepS(PRWTSEM);
msg = currp->p_rdymsg;