ChibiOS/RT  5.1.0
chthreads.c File Reference

Threads code. More...

#include "ch.h"

Go to the source code of this file.

Functions

thread_t_thread_init (thread_t *tp, const char *name, tprio_t prio)
 Initializes a thread structure. More...
 
void _thread_memfill (uint8_t *startp, uint8_t *endp, uint8_t v)
 Memory fill utility. More...
 
thread_tchThdCreateSuspendedI (const thread_descriptor_t *tdp)
 Creates a new thread into a static memory area. More...
 
thread_tchThdCreateSuspended (const thread_descriptor_t *tdp)
 Creates a new thread into a static memory area. More...
 
thread_tchThdCreateI (const thread_descriptor_t *tdp)
 Creates a new thread into a static memory area. More...
 
thread_tchThdCreate (const thread_descriptor_t *tdp)
 Creates a new thread into a static memory area. More...
 
thread_tchThdCreateStatic (void *wsp, size_t size, tprio_t prio, tfunc_t pf, void *arg)
 Creates a new thread into a static memory area. More...
 
thread_tchThdStart (thread_t *tp)
 Resumes a thread created with chThdCreateI(). More...
 
thread_tchThdAddRef (thread_t *tp)
 Adds a reference to a thread object. More...
 
void chThdRelease (thread_t *tp)
 Releases a reference to a thread object. More...
 
void chThdExit (msg_t msg)
 Terminates the current thread. More...
 
void chThdExitS (msg_t msg)
 Terminates the current thread. More...
 
msg_t chThdWait (thread_t *tp)
 Blocks the execution of the invoking thread until the specified thread terminates then the exit code is returned. More...
 
tprio_t chThdSetPriority (tprio_t newprio)
 Changes the running thread priority level then reschedules if necessary. More...
 
void chThdTerminate (thread_t *tp)
 Requests a thread termination. More...
 
void chThdSleep (sysinterval_t time)
 Suspends the invoking thread for the specified time. More...
 
void chThdSleepUntil (systime_t time)
 Suspends the invoking thread until the system time arrives to the specified value. More...
 
systime_t chThdSleepUntilWindowed (systime_t prev, systime_t next)
 Suspends the invoking thread until the system time arrives to the specified value. More...
 
void chThdYield (void)
 Yields the time slot. More...
 
msg_t chThdSuspendS (thread_reference_t *trp)
 Sends the current thread sleeping and sets a reference variable. More...
 
msg_t chThdSuspendTimeoutS (thread_reference_t *trp, sysinterval_t timeout)
 Sends the current thread sleeping and sets a reference variable. More...
 
void chThdResumeI (thread_reference_t *trp, msg_t msg)
 Wakes up a thread waiting on a thread reference object. More...
 
void chThdResumeS (thread_reference_t *trp, msg_t msg)
 Wakes up a thread waiting on a thread reference object. More...
 
void chThdResume (thread_reference_t *trp, msg_t msg)
 Wakes up a thread waiting on a thread reference object. More...
 
msg_t chThdEnqueueTimeoutS (threads_queue_t *tqp, sysinterval_t timeout)
 Enqueues the caller thread on a threads queue object. More...
 
void chThdDequeueNextI (threads_queue_t *tqp, msg_t msg)
 Dequeues and wakes up one thread from the threads queue object, if any. More...
 
void chThdDequeueAllI (threads_queue_t *tqp, msg_t msg)
 Dequeues and wakes up all threads from the threads queue object. More...
 

Detailed Description

Threads code.

Definition in file chthreads.c.