diff options
author | Giovanni Di Sirio <gdisirio@gmail.com> | 2017-10-03 08:50:33 +0000 |
---|---|---|
committer | Giovanni Di Sirio <gdisirio@gmail.com> | 2017-10-03 08:50:33 +0000 |
commit | 7d2486a57ad2f63c30d00d1d4302e82e10467633 (patch) | |
tree | 41445cb98d7c42bf2afa607af7b32f4b22f3d002 /os/common/oslib/include/chfifo.h | |
parent | 3a6f91354464e430dfb78bc81031815d7700bb97 (diff) | |
download | ChibiOS-7d2486a57ad2f63c30d00d1d4302e82e10467633.tar.gz ChibiOS-7d2486a57ad2f63c30d00d1d4302e82e10467633.tar.bz2 ChibiOS-7d2486a57ad2f63c30d00d1d4302e82e10467633.zip |
Mailboxes refactory for consistency.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10747 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/common/oslib/include/chfifo.h')
-rw-r--r-- | os/common/oslib/include/chfifo.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/os/common/oslib/include/chfifo.h b/os/common/oslib/include/chfifo.h index 494689f2f..8727fff84 100644 --- a/os/common/oslib/include/chfifo.h +++ b/os/common/oslib/include/chfifo.h @@ -127,7 +127,7 @@ static inline void chMailObjectInit(objects_fifo_t *ofp, size_t objsize, chGuardedPoolObjectInit(&ofp->free, objsize);
chGuardedPoolLoadArray(&ofp->free, objbuf, objn);
- chMBObjectInit(&ofp->mbx, msgbuf, (cnt_t)objn); /* TODO: make this a size_t, no more sems there.*/
+ chMBObjectInit(&ofp->mbx, msgbuf, objn);
}
/**
@@ -223,7 +223,7 @@ static inline void chFifoSendObjectS(objects_fifo_t *ofp, void *objp) {
msg_t msg;
- msg = chMBPostS(&ofp->mbx, (msg_t)objp, TIME_IMMEDIATE);
+ msg = chMBPostTimeoutS(&ofp->mbx, (msg_t)objp, TIME_IMMEDIATE);
chDbgAssert(msg == MSG_OK, "post failed");
}
@@ -240,7 +240,7 @@ static inline void chFifoSendObject(objects_fifo_t *ofp, void *objp) { msg_t msg;
- msg = chMBPost(&ofp->mbx, (msg_t)objp, TIME_IMMEDIATE);
+ msg = chMBPostTimeout(&ofp->mbx, (msg_t)objp, TIME_IMMEDIATE);
chDbgAssert(msg == MSG_OK, "post failed");
}
@@ -281,7 +281,7 @@ static inline msg_t chFifoReceiveObjectTimeoutS(objects_fifo_t *ofp, void **objpp,
systime_t timeout) {
- return chMBFetchS(&ofp->mbx, (msg_t *)objpp, timeout);
+ return chMBFetchTimeoutS(&ofp->mbx, (msg_t *)objpp, timeout);
}
/**
@@ -304,7 +304,7 @@ static inline msg_t chFifoReceiveObjectTimeout(objects_fifo_t *ofp, void **objpp,
systime_t timeout) {
- return chMBFetch(&ofp->mbx, (msg_t *)objpp, timeout);
+ return chMBFetchTimeout(&ofp->mbx, (msg_t *)objpp, timeout);
}
#endif /* CH_CFG_USE_FIFO == TRUE */
|