aboutsummaryrefslogtreecommitdiffstats
path: root/src/include
diff options
context:
space:
mode:
Diffstat (limited to 'src/include')
-rw-r--r--src/include/delta.h3
-rw-r--r--src/include/threads.h11
2 files changed, 13 insertions, 1 deletions
diff --git a/src/include/delta.h b/src/include/delta.h
index 1af774959..4365eb482 100644
--- a/src/include/delta.h
+++ b/src/include/delta.h
@@ -97,6 +97,9 @@ extern "C" {
}
#endif
+/** Returns TRUE if the speciified timer is armed.*/
+#define chVTIsArmedI(vtp) ((vtp)->vt_func != NULL)
+
#endif /* CH_USE_VIRTUAL_TIMER */
#endif /* _DELTA_H_ */
diff --git a/src/include/threads.h b/src/include/threads.h
index 0440b6007..3e1713d31 100644
--- a/src/include/threads.h
+++ b/src/include/threads.h
@@ -192,8 +192,10 @@ extern "C" {
Thread *chThdCreate(t_prio prio, t_tmode mode, void *workspace,
t_size wsize, t_tfunc pf, void *arg);
void chThdSetPriority(t_prio newprio);
- void chThdResume(Thread *tp);
void chThdExit(t_msg msg);
+#ifdef CH_USE_RESUME
+ void chThdResume(Thread *tp);
+#endif
#ifdef CH_USE_TERMINATE
void chThdTerminate(Thread *tp);
#endif
@@ -240,6 +242,13 @@ extern "C" {
*/
#define chThdGetExitEventSource(tp) (&(tp)->p_exitesource)
+/**
+ * Resumes a thread created with the \p P_SUSPENDED option or suspended with
+ * \p chThdSuspend().
+ * @param tp the pointer to the thread
+ */
+#define chThdResumeI(tp) chSchReadyI(tp)
+
#endif /* _THREADS_H_ */
/** @} */