mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-19 17:48:33 -04:00
xTaskGenericNotify() now sets xYieldPending to pdTRUE even when the 'higher priority task woken' parameter is provided - making its behaviour consistent with event objects.
Ensure tasks that are blocked indefinitely on a direct to task notification return their state as eBlocked, previously was returned as eSuspended - making its behaviour consistent with event objects. Fix typo in stream_buffer.c where "size_t xBytesAvailable ); PRIVILEGED_FUNCTION" had the semicolon in the wrong place. Add testing of Stream Buffers to the AbortDelay.c tests. Guard inclusion of C code when FreeRTOSConfig.h is included from an assembly file in the ARM7_LPC2129_IAR demo. Fix minor typos in the Windows demo comment blocks.
This commit is contained in:
parent
025088c280
commit
a3148ba638
9 changed files with 124 additions and 30 deletions
|
@ -200,7 +200,7 @@ static size_t prvWriteMessageToBuffer( StreamBuffer_t * const pxStreamBuffer,
|
|||
static size_t prvReadBytesFromBuffer( StreamBuffer_t *pxStreamBuffer,
|
||||
uint8_t *pucData,
|
||||
size_t xMaxCount,
|
||||
size_t xBytesAvailable ); PRIVILEGED_FUNCTION
|
||||
size_t xBytesAvailable ) PRIVILEGED_FUNCTION;
|
||||
|
||||
/*
|
||||
* Called by both pxStreamBufferCreate() and pxStreamBufferCreateStatic() to
|
||||
|
|
|
@ -1364,11 +1364,30 @@ static void prvAddNewTaskToReadyList( TCB_t *pxNewTCB )
|
|||
else if( pxStateList == &xSuspendedTaskList )
|
||||
{
|
||||
/* The task being queried is referenced from the suspended
|
||||
list. Is it genuinely suspended or is it block
|
||||
list. Is it genuinely suspended or is it blocked
|
||||
indefinitely? */
|
||||
if( listLIST_ITEM_CONTAINER( &( pxTCB->xEventListItem ) ) == NULL )
|
||||
{
|
||||
eReturn = eSuspended;
|
||||
#if( configUSE_TASK_NOTIFICATIONS == 1 )
|
||||
{
|
||||
/* The task does not appear on the vent list item of
|
||||
and of the RTOS objects, but could still be in the
|
||||
blocked state if it is waiting on its notification
|
||||
rather than waiting on an object. */
|
||||
if( pxTCB->ucNotifyState == taskWAITING_NOTIFICATION )
|
||||
{
|
||||
eReturn = eBlocked;
|
||||
}
|
||||
else
|
||||
{
|
||||
eReturn = eSuspended;
|
||||
}
|
||||
}
|
||||
#else
|
||||
{
|
||||
eReturn = eSuspended;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -4772,13 +4791,11 @@ TickType_t uxReturn;
|
|||
{
|
||||
*pxHigherPriorityTaskWoken = pdTRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Mark that a yield is pending in case the user is not
|
||||
using the "xHigherPriorityTaskWoken" parameter to an ISR
|
||||
safe FreeRTOS function. */
|
||||
xYieldPending = pdTRUE;
|
||||
}
|
||||
|
||||
/* Mark that a yield is pending in case the user is not
|
||||
using the "xHigherPriorityTaskWoken" parameter to an ISR
|
||||
safe FreeRTOS function. */
|
||||
xYieldPending = pdTRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -4862,13 +4879,11 @@ TickType_t uxReturn;
|
|||
{
|
||||
*pxHigherPriorityTaskWoken = pdTRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Mark that a yield is pending in case the user is not
|
||||
using the "xHigherPriorityTaskWoken" parameter in an ISR
|
||||
safe FreeRTOS function. */
|
||||
xYieldPending = pdTRUE;
|
||||
}
|
||||
|
||||
/* Mark that a yield is pending in case the user is not
|
||||
using the "xHigherPriorityTaskWoken" parameter in an ISR
|
||||
safe FreeRTOS function. */
|
||||
xYieldPending = pdTRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue