mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2026-05-12 11:42:57 -04:00
Compare commits
4 commits
7c0c890c64
...
a8c9d35152
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a8c9d35152 | ||
|
|
d1f551e253 | ||
|
|
587fe6df0d | ||
|
|
5f2cc25b17 |
5 changed files with 24 additions and 16 deletions
8
.github/workflows/kernel-demos.yml
vendored
8
.github/workflows/kernel-demos.yml
vendored
|
|
@ -13,6 +13,10 @@ jobs:
|
||||||
name: WIN32 MSVC
|
name: WIN32 MSVC
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
steps:
|
steps:
|
||||||
|
- name: Enable long paths on Windows
|
||||||
|
if: runner.os == 'Windows'
|
||||||
|
run: git config --system core.longpaths true
|
||||||
|
|
||||||
- name: Checkout the FreeRTOS/FreeRTOS Repository
|
- name: Checkout the FreeRTOS/FreeRTOS Repository
|
||||||
uses: actions/checkout@v4.1.1
|
uses: actions/checkout@v4.1.1
|
||||||
with:
|
with:
|
||||||
|
|
@ -42,6 +46,10 @@ jobs:
|
||||||
name: WIN32 MingW
|
name: WIN32 MingW
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
steps:
|
steps:
|
||||||
|
- name: Enable long paths on Windows
|
||||||
|
if: runner.os == 'Windows'
|
||||||
|
run: git config --system core.longpaths true
|
||||||
|
|
||||||
- name: Checkout the FreeRTOS/FreeRTOS Repository
|
- name: Checkout the FreeRTOS/FreeRTOS Repository
|
||||||
uses: actions/checkout@v4.1.1
|
uses: actions/checkout@v4.1.1
|
||||||
with:
|
with:
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,7 @@
|
||||||
*/
|
*/
|
||||||
#ifndef configLIST_VOLATILE
|
#ifndef configLIST_VOLATILE
|
||||||
#define configLIST_VOLATILE
|
#define configLIST_VOLATILE
|
||||||
#endif /* configSUPPORT_CROSS_MODULE_OPTIMISATION */
|
#endif /* configLIST_VOLATILE */
|
||||||
|
|
||||||
/* *INDENT-OFF* */
|
/* *INDENT-OFF* */
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
|
@ -191,7 +191,7 @@ typedef struct xLIST
|
||||||
* Access macro to get the owner of a list item. The owner of a list item
|
* Access macro to get the owner of a list item. The owner of a list item
|
||||||
* is the object (usually a TCB) that contains the list item.
|
* is the object (usually a TCB) that contains the list item.
|
||||||
*
|
*
|
||||||
* \page listGET_LIST_ITEM_OWNER listSET_LIST_ITEM_OWNER
|
* \page listGET_LIST_ITEM_OWNER listGET_LIST_ITEM_OWNER
|
||||||
* \ingroup LinkedList
|
* \ingroup LinkedList
|
||||||
*/
|
*/
|
||||||
#define listGET_LIST_ITEM_OWNER( pxListItem ) ( ( pxListItem )->pvOwner )
|
#define listGET_LIST_ITEM_OWNER( pxListItem ) ( ( pxListItem )->pvOwner )
|
||||||
|
|
@ -310,7 +310,7 @@ typedef struct xLIST
|
||||||
* Remove an item from a list. The list item has a pointer to the list that
|
* Remove an item from a list. The list item has a pointer to the list that
|
||||||
* it is in, so only the list item need be passed into the function.
|
* it is in, so only the list item need be passed into the function.
|
||||||
*
|
*
|
||||||
* @param uxListRemove The item to be removed. The item will remove itself from
|
* @param pxItemToRemove The item to be removed. The item will remove itself from
|
||||||
* the list pointed to by it's pxContainer parameter.
|
* the list pointed to by it's pxContainer parameter.
|
||||||
*
|
*
|
||||||
* @return The number of items that remain in the list after the list item has
|
* @return The number of items that remain in the list after the list item has
|
||||||
|
|
@ -491,7 +491,7 @@ void vListInsertEnd( List_t * const pxList,
|
||||||
* Remove an item from a list. The list item has a pointer to the list that
|
* Remove an item from a list. The list item has a pointer to the list that
|
||||||
* it is in, so only the list item need be passed into the function.
|
* it is in, so only the list item need be passed into the function.
|
||||||
*
|
*
|
||||||
* @param uxListRemove The item to be removed. The item will remove itself from
|
* @param pxItemToRemove The item to be removed. The item will remove itself from
|
||||||
* the list pointed to by it's pxContainer parameter.
|
* the list pointed to by it's pxContainer parameter.
|
||||||
*
|
*
|
||||||
* @return The number of items that remain in the list after the list item has
|
* @return The number of items that remain in the list after the list item has
|
||||||
|
|
|
||||||
|
|
@ -560,14 +560,14 @@ typedef StreamBufferHandle_t MessageBufferHandle_t;
|
||||||
*
|
*
|
||||||
* Example use:
|
* Example use:
|
||||||
* @code{c}
|
* @code{c}
|
||||||
* void vAFunction( MessageBuffer_t xMessageBuffer )
|
* void vAFunction( MessageBufferHandle_t xMessageBuffer )
|
||||||
* {
|
* {
|
||||||
* uint8_t ucRxData[ 20 ];
|
* uint8_t ucRxData[ 20 ];
|
||||||
* size_t xReceivedBytes;
|
* size_t xReceivedBytes;
|
||||||
* const TickType_t xBlockTime = pdMS_TO_TICKS( 20 );
|
* const TickType_t xBlockTime = pdMS_TO_TICKS( 20 );
|
||||||
*
|
*
|
||||||
* // Receive the next message from the message buffer. Wait in the Blocked
|
* // Receive the next message from the message buffer. Wait in the Blocked
|
||||||
* // state (so not using any CPU processing time) for a maximum of 100ms for
|
* // state (so not using any CPU processing time) for a maximum of 20ms for
|
||||||
* // a message to become available.
|
* // a message to become available.
|
||||||
* xReceivedBytes = xMessageBufferReceive( xMessageBuffer,
|
* xReceivedBytes = xMessageBufferReceive( xMessageBuffer,
|
||||||
* ( void * ) ucRxData,
|
* ( void * ) ucRxData,
|
||||||
|
|
@ -655,7 +655,7 @@ typedef StreamBufferHandle_t MessageBufferHandle_t;
|
||||||
* Example use:
|
* Example use:
|
||||||
* @code{c}
|
* @code{c}
|
||||||
* // A message buffer that has already been created.
|
* // A message buffer that has already been created.
|
||||||
* MessageBuffer_t xMessageBuffer;
|
* MessageBufferHandle_t xMessageBuffer;
|
||||||
*
|
*
|
||||||
* void vAnInterruptServiceRoutine( void )
|
* void vAnInterruptServiceRoutine( void )
|
||||||
* {
|
* {
|
||||||
|
|
|
||||||
|
|
@ -760,7 +760,7 @@ size_t xStreamBufferSendFromISR( StreamBufferHandle_t xStreamBuffer,
|
||||||
*
|
*
|
||||||
* Example use:
|
* Example use:
|
||||||
* @code{c}
|
* @code{c}
|
||||||
* void vAFunction( StreamBuffer_t xStreamBuffer )
|
* void vAFunction( StreamBufferHandle_t xStreamBuffer )
|
||||||
* {
|
* {
|
||||||
* uint8_t ucRxData[ 20 ];
|
* uint8_t ucRxData[ 20 ];
|
||||||
* size_t xReceivedBytes;
|
* size_t xReceivedBytes;
|
||||||
|
|
@ -768,7 +768,7 @@ size_t xStreamBufferSendFromISR( StreamBufferHandle_t xStreamBuffer,
|
||||||
*
|
*
|
||||||
* // Receive up to another sizeof( ucRxData ) bytes from the stream buffer.
|
* // Receive up to another sizeof( ucRxData ) bytes from the stream buffer.
|
||||||
* // Wait in the Blocked state (so not using any CPU processing time) for a
|
* // Wait in the Blocked state (so not using any CPU processing time) for a
|
||||||
* // maximum of 100ms for the full sizeof( ucRxData ) number of bytes to be
|
* // maximum of 20ms for the full sizeof( ucRxData ) number of bytes to be
|
||||||
* // available.
|
* // available.
|
||||||
* xReceivedBytes = xStreamBufferReceive( xStreamBuffer,
|
* xReceivedBytes = xStreamBufferReceive( xStreamBuffer,
|
||||||
* ( void * ) ucRxData,
|
* ( void * ) ucRxData,
|
||||||
|
|
@ -840,7 +840,7 @@ size_t xStreamBufferReceive( StreamBufferHandle_t xStreamBuffer,
|
||||||
* Example use:
|
* Example use:
|
||||||
* @code{c}
|
* @code{c}
|
||||||
* // A stream buffer that has already been created.
|
* // A stream buffer that has already been created.
|
||||||
* StreamBuffer_t xStreamBuffer;
|
* StreamBufferHandle_t xStreamBuffer;
|
||||||
*
|
*
|
||||||
* void vAnInterruptServiceRoutine( void )
|
* void vAnInterruptServiceRoutine( void )
|
||||||
* {
|
* {
|
||||||
|
|
@ -1218,7 +1218,7 @@ UBaseType_t uxStreamBufferGetStreamBufferNotificationIndex( StreamBufferHandle_t
|
||||||
* stream_buffer.h
|
* stream_buffer.h
|
||||||
*
|
*
|
||||||
* @code{c}
|
* @code{c}
|
||||||
* void vStreamBufferSetStreamBufferNotificationIndex ( StreamBuffer_t xStreamBuffer, UBaseType_t uxNotificationIndex );
|
* void vStreamBufferSetStreamBufferNotificationIndex ( StreamBufferHandle_t xStreamBuffer, UBaseType_t uxNotificationIndex );
|
||||||
* @endcode
|
* @endcode
|
||||||
*
|
*
|
||||||
* Set the task notification index used for the supplied stream buffer.
|
* Set the task notification index used for the supplied stream buffer.
|
||||||
|
|
|
||||||
|
|
@ -408,7 +408,7 @@ static void prvProcessSimulatedInterrupts( void )
|
||||||
|
|
||||||
/* Create a pending tick to ensure the first task is started as soon as
|
/* Create a pending tick to ensure the first task is started as soon as
|
||||||
* this thread pends. */
|
* this thread pends. */
|
||||||
ulPendingInterrupts |= ( 1 << portINTERRUPT_TICK );
|
ulPendingInterrupts |= ( 1UL << portINTERRUPT_TICK );
|
||||||
SetEvent( pvInterruptEvent );
|
SetEvent( pvInterruptEvent );
|
||||||
|
|
||||||
while( xPortRunning == pdTRUE )
|
while( xPortRunning == pdTRUE )
|
||||||
|
|
@ -447,7 +447,7 @@ static void prvProcessSimulatedInterrupts( void )
|
||||||
if( ulIsrHandler[ i ]() != pdFALSE )
|
if( ulIsrHandler[ i ]() != pdFALSE )
|
||||||
{
|
{
|
||||||
/* A bit mask is used purely to help debugging. */
|
/* A bit mask is used purely to help debugging. */
|
||||||
ulSwitchRequired |= ( 1 << i );
|
ulSwitchRequired |= ( 1UL << i );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -580,7 +580,7 @@ void vPortCloseRunningThread( void * pvTaskToDelete,
|
||||||
if( pvInterruptEventMutex != NULL )
|
if( pvInterruptEventMutex != NULL )
|
||||||
{
|
{
|
||||||
WaitForSingleObject( pvInterruptEventMutex, INFINITE );
|
WaitForSingleObject( pvInterruptEventMutex, INFINITE );
|
||||||
ulPendingInterrupts |= ( 1 << portINTERRUPT_YIELD );
|
ulPendingInterrupts |= ( 1UL << portINTERRUPT_YIELD );
|
||||||
ReleaseMutex( pvInterruptEventMutex );
|
ReleaseMutex( pvInterruptEventMutex );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -604,7 +604,7 @@ void vPortGenerateSimulatedInterrupt( uint32_t ulInterruptNumber )
|
||||||
if( ( ulInterruptNumber < portMAX_INTERRUPTS ) && ( pvInterruptEventMutex != NULL ) )
|
if( ( ulInterruptNumber < portMAX_INTERRUPTS ) && ( pvInterruptEventMutex != NULL ) )
|
||||||
{
|
{
|
||||||
WaitForSingleObject( pvInterruptEventMutex, INFINITE );
|
WaitForSingleObject( pvInterruptEventMutex, INFINITE );
|
||||||
ulPendingInterrupts |= ( 1 << ulInterruptNumber );
|
ulPendingInterrupts |= ( 1UL << ulInterruptNumber );
|
||||||
|
|
||||||
/* The simulated interrupt is now held pending, but don't actually
|
/* The simulated interrupt is now held pending, but don't actually
|
||||||
* process it yet if this call is within a critical section. It is
|
* process it yet if this call is within a critical section. It is
|
||||||
|
|
@ -645,7 +645,7 @@ void vPortGenerateSimulatedInterruptFromWindowsThread( uint32_t ulInterruptNumbe
|
||||||
|
|
||||||
/* Pending a user defined interrupt to be handled in simulated interrupt
|
/* Pending a user defined interrupt to be handled in simulated interrupt
|
||||||
* handler thread. */
|
* handler thread. */
|
||||||
ulPendingInterrupts |= ( 1 << ulInterruptNumber );
|
ulPendingInterrupts |= ( 1UL << ulInterruptNumber );
|
||||||
|
|
||||||
/* The interrupt is now pending - notify the simulated interrupt
|
/* The interrupt is now pending - notify the simulated interrupt
|
||||||
* handler thread. Must be outside of a critical section to get here so
|
* handler thread. Must be outside of a critical section to get here so
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue