diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2014-09-10 12:35:59 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2014-09-10 12:35:59 +0000 |
commit | 3b9ae6825f753e21f2db109d7b1005a6acfe475c (patch) | |
tree | 96de78ad0895d074d075c97a145c4dbbdb4c02b1 /os/rt/include/chthreads.h | |
parent | 530c3a6f9e58a9b7dd2439424bde767d136cbef3 (diff) | |
download | ChibiOS-3b9ae6825f753e21f2db109d7b1005a6acfe475c.tar.gz ChibiOS-3b9ae6825f753e21f2db109d7b1005a6acfe475c.tar.bz2 ChibiOS-3b9ae6825f753e21f2db109d7b1005a6acfe475c.zip |
Added function chThdQueueIsEmptyI(), fixed a naming error in threads queues static initializer.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7255 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/rt/include/chthreads.h')
-rw-r--r-- | os/rt/include/chthreads.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/os/rt/include/chthreads.h b/os/rt/include/chthreads.h index 03ac3fba7..ca2d3bcbc 100644 --- a/os/rt/include/chthreads.h +++ b/os/rt/include/chthreads.h @@ -376,6 +376,23 @@ static inline void chThdQueueObjectInit(threads_queue_t *tqp) { queue_init(tqp);
}
+/**
+ * @brief Evaluates to @p true if the specified queue is empty.
+ *
+ * @param[out] tqp pointer to the threads queue object
+ * @return The queue status.
+ * @retval false if the queue is not empty.
+ * @retval true if the queue is empty.
+ *
+ * @iclass
+ */
+static inline bool chThdQueueIsEmptyI(threads_queue_t *tqp) {
+
+ chDbgCheckClassI();
+
+ return queue_isempty(tqp);
+}
+
#endif /* _CHTHREADS_H_ */
/** @} */
|