summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/score/thread.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2021-10-29 09:30:13 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2021-11-23 11:00:28 +0100
commitfc64e837c3544c3462539237fec4e90726aa8727 (patch)
treeb496ba1164e5d48e7b58115d8978182ae12ed116 /cpukit/include/rtems/score/thread.h
parentscore: _Scheduler_SMP_Schedule_highest_ready() (diff)
downloadrtems-fc64e837c3544c3462539237fec4e90726aa8727.tar.bz2
score: Rework ask for help requests
Process ask for help requests on the current processor. This avoids using inter-processor interrupts to make the system behaviour a bit more predictable. Update #4531.
Diffstat (limited to 'cpukit/include/rtems/score/thread.h')
-rw-r--r--cpukit/include/rtems/score/thread.h20
1 files changed, 17 insertions, 3 deletions
diff --git a/cpukit/include/rtems/score/thread.h b/cpukit/include/rtems/score/thread.h
index 4c8a97c0f7..23ed8e1406 100644
--- a/cpukit/include/rtems/score/thread.h
+++ b/cpukit/include/rtems/score/thread.h
@@ -306,10 +306,24 @@ typedef struct {
Chain_Control Scheduler_nodes;
/**
- * @brief Node for the Per_CPU_Control::Threads_in_need_for_help chain.
+ * @brief If an ask for help request for the thread is pending, then this
+ * member references the processor on which the ask for help request is
+ * registered, otherwise it is NULL.
*
- * This chain is protected by the Per_CPU_Control::Lock lock of the assigned
- * processor.
+ * Depending on the state of the thread and usage context, this member is
+ * protected by the Per_CPU_Control::Lock lock of the referenced processor,
+ * the scheduler lock of the thread (Thread_Scheduler_control::Lock), or the
+ * thread state lock.
+ */
+ struct Per_CPU_Control *ask_for_help_cpu;
+
+ /**
+ * @brief This member is the node for the
+ * Per_CPU_Control::Threads_in_need_for_help chain.
+ *
+ * This chain is protected by the Per_CPU_Control::Lock lock of the processor
+ * on which the ask for help request is registered
+ * (Thread_Scheduler_control::ask_for_help_cpu).
*/
Chain_Node Help_node;