38#ifndef _RTEMS_SCORE_SCHEDULERPRIORITYSMPIMPL_H
39#define _RTEMS_SCORE_SCHEDULERPRIORITYSMPIMPL_H
78 _Scheduler_priority_SMP_Get_self(
context );
80 return !_Priority_bit_map_Is_empty( &self->Bit_map );
83static inline void _Scheduler_priority_SMP_Move_from_scheduled_to_ready(
89 _Scheduler_priority_SMP_Get_self(
context );
91 _Scheduler_priority_SMP_Node_downcast( scheduled_to_ready );
93 _Chain_Extract_unprotected( &node->Base.Base.Node.Chain );
94 _Scheduler_priority_Ready_queue_enqueue_first(
95 &node->Base.Base.Node.Chain,
101static inline void _Scheduler_priority_SMP_Move_from_ready_to_scheduled(
110 self = _Scheduler_priority_SMP_Get_self(
context );
111 node = _Scheduler_priority_SMP_Node_downcast( ready_to_scheduled );
113 _Scheduler_priority_Ready_queue_extract(
114 &node->Base.Base.Node.Chain,
118 insert_priority = _Scheduler_SMP_Node_priority( &node->Base.Base );
120 _Chain_Insert_ordered_unprotected(
122 &node->Base.Base.Node.Chain,
124 _Scheduler_SMP_Priority_less_equal
128static inline void _Scheduler_priority_SMP_Insert_ready(
137 self = _Scheduler_priority_SMP_Get_self(
context );
138 node = _Scheduler_priority_SMP_Node_downcast( node_base );
141 _Scheduler_priority_Ready_queue_enqueue(
142 &node->Base.Base.Node.Chain,
147 _Scheduler_priority_Ready_queue_enqueue_first(
148 &node->Base.Base.Node.Chain,
155static inline void _Scheduler_priority_SMP_Extract_from_ready(
161 _Scheduler_priority_SMP_Get_self(
context );
163 _Scheduler_priority_SMP_Node_downcast( thread );
165 _Scheduler_priority_Ready_queue_extract(
166 &node->Base.Base.Node.Chain,
172static inline Scheduler_Node *_Scheduler_priority_SMP_Get_idle(
void *arg )
177 self = _Scheduler_priority_SMP_Get_self( arg );
179 _Chain_Last( self->idle_ready_queue );
180 _Scheduler_priority_Ready_queue_extract(
181 &lowest_ready->
Base.
Base.Node.Chain,
189static inline void _Scheduler_priority_SMP_Release_idle(
197 self = _Scheduler_priority_SMP_Get_self( arg );
198 node = _Scheduler_priority_SMP_Node_downcast( node_base );
200 _Scheduler_priority_Ready_queue_enqueue(
201 &node->Base.Base.Node.Chain,
207static inline void _Scheduler_priority_SMP_Do_update(
216 self = _Scheduler_priority_SMP_Get_self(
context );
217 node = _Scheduler_priority_SMP_Node_downcast( node_to_update );
219 _Scheduler_SMP_Node_update_priority( &node->Base, new_priority );
220 _Scheduler_priority_Ready_queue_update(
uint64_t Priority_Control
The thread priority control.
Definition: priority.h:91
#define SCHEDULER_PRIORITY_APPEND(priority)
Returns the priority control with the append indicator bit set.
Definition: schedulernodeimpl.h:81
#define SCHEDULER_PRIORITY_UNMAP(priority)
Returns the plain priority value.
Definition: schedulernodeimpl.h:70
#define SCHEDULER_PRIORITY_IS_APPEND(priority)
Returns true, if the item should be appended to its priority group, otherwise returns false and the i...
Definition: schedulernodeimpl.h:89
rtems_termios_device_context * context
Definition: console-config.c:62
This header file provides interfaces of the Deterministic Priority Scheduler which are only used by t...
This header file provides interfaces of the Deterministic Priority SMP Scheduler which are used by th...
This header file provides interfaces of the Simple Priority Scheduler which are only used by the impl...
This header file provides interfaces of the SMP Scheduler which are only used by the implementation.
Scheduler context.
Definition: scheduler.h:318
Scheduler node for per-thread data.
Definition: schedulernode.h:94
Chain_Control Scheduled
The chain of scheduled nodes.
Definition: schedulersmp.h:70
Scheduler_Node Base
Basic scheduler node.
Definition: schedulersmp.h:110
Scheduler context specialization for Deterministic Priority SMP schedulers.
Definition: schedulerprioritysmp.h:71
Scheduler node specialization for Deterministic Priority SMP schedulers.
Definition: schedulerprioritysmp.h:82
Scheduler_priority_Ready_queue Ready_queue
The associated ready queue of this node.
Definition: schedulerprioritysmp.h:91
Scheduler_SMP_Node Base
SMP scheduler node.
Definition: schedulerprioritysmp.h:86