mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2025-11-16 12:34:45 +00:00
@@ -497,16 +497,17 @@ typedef Thread_Control *( *Thread_queue_Surrender_operation )(
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Thread queue first operation.
|
* @brief Gets the first thread on the queue.
|
||||||
*
|
*
|
||||||
* @param[in] heads The thread queue heads.
|
* @param heads are heads of the thread queue.
|
||||||
*
|
*
|
||||||
* @retval NULL No thread is present on the thread queue.
|
* @retval NULL No thread is enqueued on the thread queue.
|
||||||
* @retval first The first thread of the thread queue according to the insert
|
*
|
||||||
* order. This thread remains on the thread queue.
|
* @return Returns the first thread on the thread queue according to the queue
|
||||||
|
* order. This thread remains on the thread queue.
|
||||||
*/
|
*/
|
||||||
typedef Thread_Control *( *Thread_queue_First_operation )(
|
typedef Thread_Control *( *Thread_queue_First_operation )(
|
||||||
Thread_queue_Heads *heads
|
const Thread_queue_Heads *heads
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -219,16 +219,16 @@ static void _Thread_queue_FIFO_extract(
|
|||||||
}
|
}
|
||||||
|
|
||||||
static Thread_Control *_Thread_queue_FIFO_first(
|
static Thread_Control *_Thread_queue_FIFO_first(
|
||||||
Thread_queue_Heads *heads
|
const Thread_queue_Heads *heads
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
Chain_Control *fifo;
|
const Chain_Control *fifo;
|
||||||
Chain_Node *first;
|
const Chain_Node *first;
|
||||||
Scheduler_Node *scheduler_node;
|
const Scheduler_Node *scheduler_node;
|
||||||
|
|
||||||
fifo = &heads->Heads.Fifo;
|
fifo = &heads->Heads.Fifo;
|
||||||
_Assert( !_Chain_Is_empty( fifo ) );
|
_Assert( !_Chain_Is_empty( fifo ) );
|
||||||
first = _Chain_First( fifo );
|
first = _Chain_Immutable_first( fifo );
|
||||||
scheduler_node = SCHEDULER_NODE_OF_WAIT_PRIORITY_NODE( first );
|
scheduler_node = SCHEDULER_NODE_OF_WAIT_PRIORITY_NODE( first );
|
||||||
|
|
||||||
return _Scheduler_Node_get_owner( scheduler_node );
|
return _Scheduler_Node_get_owner( scheduler_node );
|
||||||
@@ -589,7 +589,7 @@ static void _Thread_queue_Priority_extract(
|
|||||||
}
|
}
|
||||||
|
|
||||||
static Thread_Control *_Thread_queue_Priority_first(
|
static Thread_Control *_Thread_queue_Priority_first(
|
||||||
Thread_queue_Heads *heads
|
const Thread_queue_Heads *heads
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
Thread_queue_Priority_queue *priority_queue;
|
Thread_queue_Priority_queue *priority_queue;
|
||||||
|
|||||||
Reference in New Issue
Block a user