From d063e7b3d8733f5d1829f5b19c99be81f567fecf Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 11 Jan 2017 08:42:04 +0100 Subject: score: Replace STATES_DELAYING Replace STATES_DELAYING with STATES_WAITING_FOR_TIME. There is no need for separate timeout thread states. The Thread_Control::Timer::header and Watchdog_Control::cpu members can be used to figure out the kind of timeout. --- cpukit/score/include/rtems/score/statesimpl.h | 43 ++++----------------------- 1 file changed, 6 insertions(+), 37 deletions(-) (limited to 'cpukit/score') diff --git a/cpukit/score/include/rtems/score/statesimpl.h b/cpukit/score/include/rtems/score/statesimpl.h index 9751de0228..f90a89eb7f 100644 --- a/cpukit/score/include/rtems/score/statesimpl.h +++ b/cpukit/score/include/rtems/score/statesimpl.h @@ -74,8 +74,11 @@ extern "C" { /** This macro corresponds to a task waiting for BSD wakeup. */ #define STATES_WAITING_FOR_BSD_WAKEUP 0x00000100 -/** This macro corresponds to a task which is waiting for a timeout. */ -#define STATES_DELAYING 0x00000200 +/** + * @brief This macro corresponds to a task which is waiting for a relative or + * absolute timeout. + */ +#define STATES_WAITING_FOR_TIME 0x00000200 /** This macro corresponds to a task waiting for a period. */ #define STATES_WAITING_FOR_PERIOD 0x00000400 @@ -104,9 +107,6 @@ extern "C" { /** This macro corresponds to a task those life is changing. */ #define STATES_LIFE_IS_CHANGING 0x00040000 -/** This macro corresponds to a task waiting until a specific TOD. */ -#define STATES_WAITING_FOR_TIME 0x00080000 - /** This macro corresponds to a task being held by the debugger. */ #define STATES_DEBUGGER 0x08000000 @@ -139,8 +139,7 @@ extern "C" { STATES_WAITING_FOR_RWLOCK ) /** This macro corresponds to a task waiting which is blocked. */ -#define STATES_BLOCKED ( STATES_DELAYING | \ - STATES_LOCALLY_BLOCKED | \ +#define STATES_BLOCKED ( STATES_LOCALLY_BLOCKED | \ STATES_WAITING_FOR_TIME | \ STATES_WAITING_FOR_PERIOD | \ STATES_WAITING_FOR_EVENT | \ @@ -245,21 +244,6 @@ RTEMS_INLINE_ROUTINE bool _States_Is_suspended ( return (the_states & STATES_SUSPENDED); } -/** - * This function returns true if the DELAYING state is set in - * the_states, and false otherwise. - * - * @param[in] the_states is the task state set to test - * - * @return This method returns true if the desired state condition is set. - */ -RTEMS_INLINE_ROUTINE bool _States_Is_delaying ( - States_Control the_states -) -{ - return (the_states & STATES_DELAYING); -} - /** * This function returns true if the WAITING_FOR_SEGMENT state is set in * the_states, and false otherwise. @@ -350,21 +334,6 @@ RTEMS_INLINE_ROUTINE bool _States_Is_waiting_for_semaphore ( return (the_states & STATES_WAITING_FOR_SEMAPHORE); } -/** - * This function returns true if the WAITING_FOR_TIME state is set in - * the_states, and false otherwise. - * - * @param[in] the_states is the task state set to test - * - * @return This method returns true if the desired state condition is set. - */ -RTEMS_INLINE_ROUTINE bool _States_Is_waiting_for_time ( - States_Control the_states -) -{ - return (the_states & STATES_WAITING_FOR_TIME); -} - /** * This function returns true if the WAITING_FOR_TIME state is set in * the_states, and false otherwise. -- cgit v1.2.3