summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-05-13 11:22:39 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-05-20 07:49:38 +0200
commit862a0eeb1197539c0e69381cb5aaccb9e1c64c0f (patch)
tree05a2d2116e3a521ddf3843aba5382354507e856b /cpukit/score/include/rtems
parentscore: Split _Thread_Restart() (diff)
downloadrtems-862a0eeb1197539c0e69381cb5aaccb9e1c64c0f.tar.bz2
score: Rework _Thread_Restart_other()
Rework _Thread_Restart_other() to use _Thread_Change_life_locked(). Cope with concurrent change requests by means of a pending request counter. Update #2555. Update #2626.
Diffstat (limited to '')
-rw-r--r--cpukit/score/include/rtems/score/statesimpl.h4
-rw-r--r--cpukit/score/include/rtems/score/thread.h5
2 files changed, 7 insertions, 2 deletions
diff --git a/cpukit/score/include/rtems/score/statesimpl.h b/cpukit/score/include/rtems/score/statesimpl.h
index 8aebba068e..a560329a17 100644
--- a/cpukit/score/include/rtems/score/statesimpl.h
+++ b/cpukit/score/include/rtems/score/statesimpl.h
@@ -78,8 +78,8 @@ extern "C" {
#define STATES_WAITING_FOR_BSD_WAKEUP 0x80000
/** This macro corresponds to a task being a zombie. */
#define STATES_ZOMBIE 0x200000
-/** This macro corresponds to a task restarting. */
-#define STATES_RESTARTING 0x800000
+/** This macro corresponds to a task those life is changing. */
+#define STATES_LIFE_IS_CHANGING 0x800000
/** This macro corresponds to a task waiting for a join. */
#define STATES_WAITING_FOR_JOIN 0x1000000
/** This macro corresponds to a task waiting for a <sys/lock.h> mutex. */
diff --git a/cpukit/score/include/rtems/score/thread.h b/cpukit/score/include/rtems/score/thread.h
index 9b35b85f91..6d41d4d4c7 100644
--- a/cpukit/score/include/rtems/score/thread.h
+++ b/cpukit/score/include/rtems/score/thread.h
@@ -543,6 +543,11 @@ typedef struct {
* @brief The current thread life state.
*/
Thread_Life_state state;
+
+ /**
+ * @brief The count of pending life change requests.
+ */
+ uint32_t pending_life_change_requests;
} Thread_Life_control;
#if defined(RTEMS_SMP)