98 #ifndef INC_FREERTOS_H 99 #error FreeRTOS.h must be included before list.h 133 #ifndef configLIST_VOLATILE 134 #define configLIST_VOLATILE 146 #if( configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES == 0 ) 148 #define listFIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE 149 #define listSECOND_LIST_ITEM_INTEGRITY_CHECK_VALUE 150 #define listFIRST_LIST_INTEGRITY_CHECK_VALUE 151 #define listSECOND_LIST_INTEGRITY_CHECK_VALUE 152 #define listSET_FIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE( pxItem ) 153 #define listSET_SECOND_LIST_ITEM_INTEGRITY_CHECK_VALUE( pxItem ) 154 #define listSET_LIST_INTEGRITY_CHECK_1_VALUE( pxList ) 155 #define listSET_LIST_INTEGRITY_CHECK_2_VALUE( pxList ) 156 #define listTEST_LIST_ITEM_INTEGRITY( pxItem ) 157 #define listTEST_LIST_INTEGRITY( pxList ) 160 #define listFIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE TickType_t xListItemIntegrityValue1; 161 #define listSECOND_LIST_ITEM_INTEGRITY_CHECK_VALUE TickType_t xListItemIntegrityValue2; 162 #define listFIRST_LIST_INTEGRITY_CHECK_VALUE TickType_t xListIntegrityValue1; 163 #define listSECOND_LIST_INTEGRITY_CHECK_VALUE TickType_t xListIntegrityValue2; 166 #define listSET_FIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE( pxItem ) ( pxItem )->xListItemIntegrityValue1 = pdINTEGRITY_CHECK_VALUE 167 #define listSET_SECOND_LIST_ITEM_INTEGRITY_CHECK_VALUE( pxItem ) ( pxItem )->xListItemIntegrityValue2 = pdINTEGRITY_CHECK_VALUE 168 #define listSET_LIST_INTEGRITY_CHECK_1_VALUE( pxList ) ( pxList )->xListIntegrityValue1 = pdINTEGRITY_CHECK_VALUE 169 #define listSET_LIST_INTEGRITY_CHECK_2_VALUE( pxList ) ( pxList )->xListIntegrityValue2 = pdINTEGRITY_CHECK_VALUE 173 #define listTEST_LIST_ITEM_INTEGRITY( pxItem ) configASSERT( ( ( pxItem )->xListItemIntegrityValue1 == pdINTEGRITY_CHECK_VALUE ) && ( ( pxItem )->xListItemIntegrityValue2 == pdINTEGRITY_CHECK_VALUE ) ) 174 #define listTEST_LIST_INTEGRITY( pxList ) configASSERT( ( ( pxList )->xListIntegrityValue1 == pdINTEGRITY_CHECK_VALUE ) && ( ( pxList )->xListIntegrityValue2 == pdINTEGRITY_CHECK_VALUE ) ) 183 listFIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE
184 configLIST_VOLATILE TickType_t xItemValue;
185 struct xLIST_ITEM * configLIST_VOLATILE pxNext;
186 struct xLIST_ITEM * configLIST_VOLATILE pxPrevious;
188 void * configLIST_VOLATILE pvContainer;
189 listSECOND_LIST_ITEM_INTEGRITY_CHECK_VALUE
195 listFIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE
196 configLIST_VOLATILE TickType_t xItemValue;
197 struct xLIST_ITEM * configLIST_VOLATILE pxNext;
198 struct xLIST_ITEM * configLIST_VOLATILE pxPrevious;
207 listFIRST_LIST_INTEGRITY_CHECK_VALUE
208 configLIST_VOLATILE UBaseType_t uxNumberOfItems;
209 ListItem_t * configLIST_VOLATILE pxIndex;
210 MiniListItem_t xListEnd;
211 listSECOND_LIST_INTEGRITY_CHECK_VALUE
221 #define listSET_LIST_ITEM_OWNER( pxListItem, pxOwner ) ( ( pxListItem )->pvOwner = ( void * ) ( pxOwner ) ) 230 #define listGET_LIST_ITEM_OWNER( pxListItem ) ( ( pxListItem )->pvOwner ) 239 #define listSET_LIST_ITEM_VALUE( pxListItem, xValue ) ( ( pxListItem )->xItemValue = ( xValue ) ) 249 #define listGET_LIST_ITEM_VALUE( pxListItem ) ( ( pxListItem )->xItemValue ) 258 #define listGET_ITEM_VALUE_OF_HEAD_ENTRY( pxList ) ( ( ( pxList )->xListEnd ).pxNext->xItemValue ) 266 #define listGET_HEAD_ENTRY( pxList ) ( ( ( pxList )->xListEnd ).pxNext ) 274 #define listGET_NEXT( pxListItem ) ( ( pxListItem )->pxNext ) 282 #define listGET_END_MARKER( pxList ) ( ( ListItem_t const * ) ( &( ( pxList )->xListEnd ) ) ) 291 #define listLIST_IS_EMPTY( pxList ) ( ( BaseType_t ) ( ( pxList )->uxNumberOfItems == ( UBaseType_t ) 0 ) ) 296 #define listCURRENT_LIST_LENGTH( pxList ) ( ( pxList )->uxNumberOfItems ) 318 #define listGET_OWNER_OF_NEXT_ENTRY( pxTCB, pxList ) \ 320 List_t * const pxConstList = ( pxList ); \ 323 ( pxConstList )->pxIndex = ( pxConstList )->pxIndex->pxNext; \ 324 if( ( void * ) ( pxConstList )->pxIndex == ( void * ) &( ( pxConstList )->xListEnd ) ) \ 326 ( pxConstList )->pxIndex = ( pxConstList )->pxIndex->pxNext; \ 328 ( pxTCB ) = ( pxConstList )->pxIndex->pvOwner; \ 348 #define listGET_OWNER_OF_HEAD_ENTRY( pxList ) ( (&( ( pxList )->xListEnd ))->pxNext->pvOwner ) 359 #define listIS_CONTAINED_WITHIN( pxList, pxListItem ) ( ( BaseType_t ) ( ( pxListItem )->pvContainer == ( void * ) ( pxList ) ) ) 367 #define listLIST_ITEM_CONTAINER( pxListItem ) ( ( pxListItem )->pvContainer ) 374 #define listLIST_IS_INITIALISED( pxList ) ( ( pxList )->xListEnd.xItemValue == portMAX_DELAY ) 386 void vListInitialise( List_t *
const pxList ) PRIVILEGED_FUNCTION;
397 void vListInitialiseItem( ListItem_t *
const pxItem ) PRIVILEGED_FUNCTION;
410 void vListInsert( List_t *
const pxList, ListItem_t *
const pxNewListItem ) PRIVILEGED_FUNCTION;
431 void vListInsertEnd( List_t *
const pxList, ListItem_t *
const pxNewListItem ) PRIVILEGED_FUNCTION;
446 UBaseType_t uxListRemove( ListItem_t *
const pxItemToRemove ) PRIVILEGED_FUNCTION;