diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2009-01-20 16:26:48 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2009-01-20 16:26:48 +0000 |
commit | 22e22db0161126d1c58a07e2323662efc18d6c86 (patch) | |
tree | e59efd65935cdb9d1358a598925a0a3fa5ace5fd /src/chschd.c | |
parent | b1d77bf4bc7fb6e89b5280d99f401caa50c8a0d8 (diff) | |
download | ChibiOS-22e22db0161126d1c58a07e2323662efc18d6c86.tar.gz ChibiOS-22e22db0161126d1c58a07e2323662efc18d6c86.tar.bz2 ChibiOS-22e22db0161126d1c58a07e2323662efc18d6c86.zip |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@649 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'src/chschd.c')
-rw-r--r-- | src/chschd.c | 36 |
1 files changed, 17 insertions, 19 deletions
diff --git a/src/chschd.c b/src/chschd.c index 91a9ea0b0..913cac83d 100644 --- a/src/chschd.c +++ b/src/chschd.c @@ -29,7 +29,7 @@ ReadyList rlist; /** @endcond */ /** - * Scheduler initialization. + * @brief Scheduler initialization. * @note Internally invoked by the @p chSysInit(). */ void chSchInit(void) { @@ -42,7 +42,7 @@ void chSchInit(void) { } /** - * Inserts a thread in the Ready List. + * @brief Inserts a thread in the Ready List. * * @param tp the Thread to be made ready * @return The Thread pointer. @@ -70,9 +70,10 @@ Thread *chSchReadyI(Thread *tp) { } /** - * Puts the current thread to sleep into the specified state, the next highest - * priority thread becomes running. The threads states are described into - * @p threads.h + * @brief Puts the current thread to sleep into the specified state. + * @details The next highest priority thread becomes running. The threads + * states are described into @p threads.h. + * * @param newstate the new thread state * @note The function must be called in the system mutex zone. * @note The function is not meant to be used in the user code directly. @@ -104,11 +105,9 @@ static void wakeup(void *p) { } /** - * Puts the current thread to sleep. - * - * Puts the current thread to sleep into the specified state. The next highest - * priority thread becomes running. The thread put to sleep is awakened after - * the specified time has elapsed. + * @brief Puts the current thread to sleep into the specified state. + * @details The next highest priority thread becomes running. The thread put + * to sleep is awakened after the specified time has elapsed. * * @param newstate the new thread state * @param time the number of ticks before the operation timeouts. the value @@ -134,10 +133,10 @@ msg_t chSchGoSleepTimeoutS(tstate_t newstate, systime_t time) { } /** - * Wakes up a thread. + * @brief Wakes up a thread. + * @details The thread is inserted into the ready list or immediately made + * running depending on its relative priority compared to the current thread. * - * The thread is inserted into the ready list or immediately made running - * depending on its relative priority compared to the current thread. * @param ntp the Thread to be made ready * @param msg message to the awakened thread * @note The function must be called in the system mutex zone. @@ -170,7 +169,7 @@ void chSchWakeupS(Thread *ntp, msg_t msg) { } /** - * Switch to the first thread on the runnable queue. + * @brief Switches to the first thread on the runnable queue. * * @note It is intended to be called if @p chSchRescRequiredI() evaluates to @p TRUE. */ @@ -190,10 +189,9 @@ void chSchDoRescheduleI(void) { } /** - * Reschedule only if a higher priority thread is runnable. - * - * If a thread with a higher priority than the current thread is in the - * ready list then make the higher priority thread running. + * @brief Performs a reschedulation if a higher priority thread is runnable. + * @details If a thread with a higher priority than the current thread is in + * the ready list then make the higher priority thread running. * * @note The function must be called in the system mutex zone. */ @@ -205,7 +203,7 @@ void chSchRescheduleS(void) { } /** - * Evaluates if rescheduling is required. + * @brief Evaluates if a reschedulation is required. * * @retval TRUE if there is a thread that should go in running state. * @retval FALSE if a reschedulation is not required. |