mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-09-13 01:27:48 -04:00
Clarify list usage in xTaskRemoveFromEventList
This commit is contained in:
parent
7649ebabd5
commit
f99a788336
1 changed files with 9 additions and 2 deletions
11
tasks.c
11
tasks.c
|
@ -3092,8 +3092,15 @@ void vTaskPlaceOnEventList( List_t * const pxEventList,
|
||||||
|
|
||||||
/* Place the event list item of the TCB in the appropriate event list.
|
/* Place the event list item of the TCB in the appropriate event list.
|
||||||
* This is placed in the list in priority order so the highest priority task
|
* This is placed in the list in priority order so the highest priority task
|
||||||
* is the first to be woken by the event. The queue that contains the event
|
* is the first to be woken by the event.
|
||||||
* list is locked, preventing simultaneous access from interrupts. */
|
*
|
||||||
|
* Note: Lists are sorted in ascending order by ListItem_t.xItemValue.
|
||||||
|
* Normally, the xItemValue of a TCB's ListItem_t members is:
|
||||||
|
* xItemValue = ( configMAX_PRIORITIES - uxPriority )
|
||||||
|
* Therefore, the event list is sorted in descending priority order.
|
||||||
|
*
|
||||||
|
* The queue that contains the event list is locked, preventing
|
||||||
|
* simultaneous access from interrupts. */
|
||||||
vListInsert( pxEventList, &( pxCurrentTCB->xEventListItem ) );
|
vListInsert( pxEventList, &( pxCurrentTCB->xEventListItem ) );
|
||||||
|
|
||||||
prvAddCurrentTaskToDelayedList( xTicksToWait, pdTRUE );
|
prvAddCurrentTaskToDelayedList( xTicksToWait, pdTRUE );
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue