From 220771565f3e8397409a6bc7520db00e7038efe8 Mon Sep 17 00:00:00 2001 From: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com> Date: Thu, 19 Oct 2023 11:20:19 +0530 Subject: [PATCH 1/7] Removes redundant API calls in MPU wrappers (#838) * Remove redundant API calls in Queue wrappers --- portable/Common/mpu_wrappers_v2.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/portable/Common/mpu_wrappers_v2.c b/portable/Common/mpu_wrappers_v2.c index 30efa077338..fb4bd45fe87 100644 --- a/portable/Common/mpu_wrappers_v2.c +++ b/portable/Common/mpu_wrappers_v2.c @@ -2133,7 +2133,7 @@ if( pvItemToQueue != NULL ) { xIsItemToQueueReadable = xPortIsAuthorizedToAccessBuffer( pvItemToQueue, - uxQueueGetQueueItemSize( xInternalQueueHandle ), + uxQueueItemSize, tskMPU_READ_PERMISSION ); } @@ -2246,7 +2246,7 @@ ) { xIsReceiveBufferWritable = xPortIsAuthorizedToAccessBuffer( pvBuffer, - uxQueueGetQueueItemSize( xInternalQueueHandle ), + uxQueueItemSize, tskMPU_WRITE_PERMISSION ); if( xIsReceiveBufferWritable == pdTRUE ) @@ -2298,7 +2298,7 @@ ) { xIsReceiveBufferWritable = xPortIsAuthorizedToAccessBuffer( pvBuffer, - uxQueueGetQueueItemSize( xInternalQueueHandle ), + uxQueueItemSize, tskMPU_WRITE_PERMISSION ); if( xIsReceiveBufferWritable == pdTRUE ) From b32aafe4dc16cb2474e0516019c2356cd01fb1c1 Mon Sep 17 00:00:00 2001 From: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com> Date: Thu, 19 Oct 2023 12:08:22 +0530 Subject: [PATCH 2/7] Fix size alignment in the integer overflow issue (#839) --- portable/Common/mpu_wrappers_v2.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/portable/Common/mpu_wrappers_v2.c b/portable/Common/mpu_wrappers_v2.c index fb4bd45fe87..87e849edf1b 100644 --- a/portable/Common/mpu_wrappers_v2.c +++ b/portable/Common/mpu_wrappers_v2.c @@ -113,14 +113,14 @@ #define CONVERT_TO_INTERNAL_INDEX( lIndex ) ( ( lIndex ) - INDEX_OFFSET ) /** - * @brief Max value that fits in a size_t type. + * @brief Max value that fits in a uint32_t type. */ - #define mpuSIZE_MAX ( ~( ( size_t ) 0 ) ) + #define mpuUINT32_MAX ( ~( ( uint32_t ) 0 ) ) /** * @brief Check if multiplying a and b will result in overflow. */ - #define mpuMULTIPLY_WILL_OVERFLOW( a, b ) ( ( ( a ) > 0 ) && ( ( b ) > ( mpuSIZE_MAX / ( a ) ) ) ) + #define mpuMULTIPLY_UINT32_WILL_OVERFLOW( a, b ) ( ( ( a ) > 0 ) && ( ( b ) > ( mpuUINT32_MAX / ( a ) ) ) ) /** * @brief Get the index of a free slot in the kernel object pool. @@ -1048,11 +1048,13 @@ UBaseType_t uxReturn = 0; UBaseType_t xIsTaskStatusArrayWriteable = pdFALSE; UBaseType_t xIsTotalRunTimeWriteable = pdFALSE; + uint32_t ulArraySize = ( uint32_t ) uxArraySize; + uint32_t ulTaskStatusSize = ( uint32_t ) sizeof( TaskStatus_t ); - if( mpuMULTIPLY_WILL_OVERFLOW( sizeof( TaskStatus_t ), uxArraySize ) == 0 ) + if( mpuMULTIPLY_UINT32_WILL_OVERFLOW( ulTaskStatusSize, ulArraySize ) == 0 ) { xIsTaskStatusArrayWriteable = xPortIsAuthorizedToAccessBuffer( pxTaskStatusArray, - sizeof( TaskStatus_t ) * uxArraySize, + ulTaskStatusSize * ulArraySize, tskMPU_WRITE_PERMISSION ); if( pulTotalRunTime != NULL ) @@ -1065,7 +1067,7 @@ if( ( xIsTaskStatusArrayWriteable == pdTRUE ) && ( ( pulTotalRunTime == NULL ) || ( xIsTotalRunTimeWriteable == pdTRUE ) ) ) { - uxReturn = uxTaskGetSystemState( pxTaskStatusArray, uxArraySize, pulTotalRunTime ); + uxReturn = uxTaskGetSystemState( pxTaskStatusArray, ( UBaseType_t ) ulArraySize, pulTotalRunTime ); } } From a936a1b156450f2454b335f711776c8cce9bc668 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Thu, 19 Oct 2023 10:08:24 -0700 Subject: [PATCH 3/7] Kernel Checker CI Workflow File Updates (#804) * Perform sparse checkout of just the .github folder for the header check instead of all the files. Update python checkout version being used. Update the version of the get changed files action being used. * Use echo groups on the header check --- .github/workflows/kernel-checks.yml | 37 +++++++++++++++++++++++------ 1 file changed, 30 insertions(+), 7 deletions(-) diff --git a/.github/workflows/kernel-checks.yml b/.github/workflows/kernel-checks.yml index 679ede23e3d..cfaec5b1213 100644 --- a/.github/workflows/kernel-checks.yml +++ b/.github/workflows/kernel-checks.yml @@ -9,10 +9,7 @@ jobs: steps: # Install python 3 - name: Tool Setup - uses: actions/setup-python@v2 - with: - python-version: 3.7.10 - architecture: x64 + uses: actions/setup-python@v3 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -21,6 +18,7 @@ jobs: uses: actions/checkout@v3 with: repository: FreeRTOS/FreeRTOS + sparse-checkout: '.github' ref: main path: tools @@ -32,15 +30,40 @@ jobs: # Collect all affected files - name: Collecting changed files - uses: lots0logs/gh-action-get-changed-files@2.1.4 + uses: lots0logs/gh-action-get-changed-files@2.2.2 with: token: ${{ secrets.GITHUB_TOKEN }} # Run checks - - name: Check File Headers + - env: + bashPass: \033[32;1mPASSED - + bashInfo: \033[33;1mINFO - + bashFail: \033[31;1mFAILED - + bashEnd: \033[0m + stepName: Check File Headers + name: ${{ env.stepName }} + shell: bash run: | + # ${{ env.stepName }} + echo -e "::group::${{ env.bashInfo }} Install Dependencies ${{ env.bashEnd }}" + + # Copy the common tools from the FreeRTOS/FreeRTOS repo. mv tools/.github/scripts/common inspect/.github/scripts + + # Install the necessary python dependencies pip install -r inspect/.github/scripts/common/requirements.txt cd inspect + + echo -e "::group::${{ env.bashInfo }} ${{ env.stepName }} ${{ env.bashEnd }}" + + # Use the python script to check the copyright header of modified files. .github/scripts/kernel_checker.py --json ${HOME}/files_modified.json ${HOME}/files_added.json ${HOME}/files_renamed.json - exit $? + exitStatus=$? + echo -e "::endgroup::" + + if [ $exitStatus -eq 0 ]; then + echo -e "${{ env.bashPass }} ${{ env.stepName }} ${{ env.bashEnd }}" + else + echo -e "${{ env.bashFail }} ${{ env.stepName }} ${{ env.bashEnd }}" + fi + exit $exitStatus From 7562ebc6e13ae560de98b00ac96c2d518b0c6639 Mon Sep 17 00:00:00 2001 From: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com> Date: Fri, 20 Oct 2023 22:08:03 +0530 Subject: [PATCH 4/7] Covert object type check to runtime check (#846) * Covert object type check to runtime check It was checked using assert earlier. --------- Signed-off-by: Gaurav Aggarwal --- portable/Common/mpu_wrappers_v2.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/portable/Common/mpu_wrappers_v2.c b/portable/Common/mpu_wrappers_v2.c index 87e849edf1b..beb21d271fe 100644 --- a/portable/Common/mpu_wrappers_v2.c +++ b/portable/Common/mpu_wrappers_v2.c @@ -324,9 +324,16 @@ static OpaqueObjectHandle_t MPU_GetHandleAtIndex( int32_t lIndex, uint32_t ulKernelObjectType ) /* PRIVILEGED_FUNCTION */ { + OpaqueObjectHandle_t xObjectHandle = NULL; + configASSERT( IS_INTERNAL_INDEX_VALID( lIndex ) != pdFALSE ); - configASSERT( xKernelObjectPool[ lIndex ].ulKernelObjectType == ulKernelObjectType ); - return xKernelObjectPool[ lIndex ].xInternalObjectHandle; + + if( xKernelObjectPool[ lIndex ].ulKernelObjectType == ulKernelObjectType ) + { + xObjectHandle = xKernelObjectPool[ lIndex ].xInternalObjectHandle; + } + + return xObjectHandle; } /*-----------------------------------------------------------*/ From 9f4a0e308b311e9fa7ae112a74a27b62a2bbb138 Mon Sep 17 00:00:00 2001 From: Boris van der Meer Date: Mon, 23 Oct 2023 08:57:54 +0200 Subject: [PATCH 5/7] Remove default behaviour of FREERTOS_HEAP. (#807) To build a complete static application (configSUPPORT_DYNAMIC_ALLOCATION set to 0) an ugly workaround is necessary, because when FREERTOS_HEAP is not set, heap 4 is automatically selected in the current CMake. Co-authored-by: kar-rahul-aws <118818625+kar-rahul-aws@users.noreply.github.com> Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com> Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com> Co-authored-by: Soren Ptak --- CMakeLists.txt | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5d27a58c6b7..984e36ecd2c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -8,10 +8,12 @@ cmake_minimum_required(VERSION 3.15) # # DEPRECATED: FREERTOS_CONFIG_FILE_DIRECTORY - but still supported if no freertos_config defined for now. # May be removed at some point in the future. +# # User can choose which heap implementation to use (either the implementations -# included with FreeRTOS [1..5] or a custom implementation ) by providing the -# option FREERTOS_HEAP. If the option is not set, the cmake will default to -# using heap_4.c. +# included with FreeRTOS [1..5] or a custom implementation) by providing the +# option FREERTOS_HEAP. When dynamic allocation is used, the user must specify a +# heap implementation. If the option is not set, the cmake will use no heap +# implementation (e.g. when only static allocation is used). # `freertos_config` target defines the path to FreeRTOSConfig.h and optionally other freertos based config files if(NOT TARGET freertos_config ) @@ -37,9 +39,6 @@ if(NOT TARGET freertos_config ) endif() endif() -# Heap number or absolute path to custom heap implementation provided by user -set(FREERTOS_HEAP "4" CACHE STRING "FreeRTOS heap model number. 1 .. 5. Or absolute path to custom heap source file") - # FreeRTOS port option if(NOT FREERTOS_PORT) message(WARNING " FREERTOS_PORT is not set. Please specify it from top-level CMake file (example):\n" @@ -285,11 +284,16 @@ target_sources(freertos_kernel PRIVATE stream_buffer.c tasks.c timers.c - - # If FREERTOS_HEAP is digit between 1 .. 5 - it is heap number, otherwise - it is path to custom heap source file - $>,${FREERTOS_HEAP},portable/MemMang/heap_${FREERTOS_HEAP}.c> ) +if (DEFINED FREERTOS_HEAP ) + # User specified a heap implementation add heap implementation to freertos_kernel. + target_sources(freertos_kernel PRIVATE + # If FREERTOS_HEAP is digit between 1 .. 5 - it is heap number, otherwise - it is path to custom heap source file + $>,${FREERTOS_HEAP},portable/MemMang/heap_${FREERTOS_HEAP}.c> + ) +endif() + target_link_libraries(freertos_kernel PUBLIC From fc7aca7ff239ac988b7cb28a73ca6c66f4efcb84 Mon Sep 17 00:00:00 2001 From: Darian <32921628+Dazza0@users.noreply.github.com> Date: Mon, 23 Oct 2023 15:20:24 +0800 Subject: [PATCH 6/7] Rename CPU to Core (#849) This commit renames "CPU" to "Core" for any public facing API for consistency with other SMP related APIs (e.g., "configNUMBER_OF_CORES"). Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com> --- include/FreeRTOS.h | 8 ++++---- include/task.h | 2 +- tasks.c | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/include/FreeRTOS.h b/include/FreeRTOS.h index ba7d083a625..b8153ac64dd 100644 --- a/include/FreeRTOS.h +++ b/include/FreeRTOS.h @@ -2120,12 +2120,12 @@ #define traceRETURN_xTaskGetCurrentTaskHandle( xReturn ) #endif -#ifndef traceENTER_xTaskGetCurrentTaskHandleCPU - #define traceENTER_xTaskGetCurrentTaskHandleCPU( xCoreID ) +#ifndef traceENTER_xTaskGetCurrentTaskHandleForCore + #define traceENTER_xTaskGetCurrentTaskHandleForCore( xCoreID ) #endif -#ifndef traceRETURN_xTaskGetCurrentTaskHandleCPU - #define traceRETURN_xTaskGetCurrentTaskHandleCPU( xReturn ) +#ifndef traceRETURN_xTaskGetCurrentTaskHandleForCore + #define traceRETURN_xTaskGetCurrentTaskHandleForCore( xReturn ) #endif #ifndef traceENTER_xTaskGetSchedulerState diff --git a/include/task.h b/include/task.h index b6850e8bdb7..c369f0c1d31 100644 --- a/include/task.h +++ b/include/task.h @@ -3539,7 +3539,7 @@ TaskHandle_t xTaskGetCurrentTaskHandle( void ) PRIVILEGED_FUNCTION; /* * Return the handle of the task running on specified core. */ -TaskHandle_t xTaskGetCurrentTaskHandleCPU( BaseType_t xCoreID ) PRIVILEGED_FUNCTION; +TaskHandle_t xTaskGetCurrentTaskHandleForCore( BaseType_t xCoreID ) PRIVILEGED_FUNCTION; /* * Shortcut used by the queue implementation to prevent unnecessary call to diff --git a/tasks.c b/tasks.c index e941907cf9c..d74a4ccac88 100644 --- a/tasks.c +++ b/tasks.c @@ -6425,18 +6425,18 @@ static void prvResetNextTaskUnblockTime( void ) return xReturn; } - TaskHandle_t xTaskGetCurrentTaskHandleCPU( BaseType_t xCoreID ) + TaskHandle_t xTaskGetCurrentTaskHandleForCore( BaseType_t xCoreID ) { TaskHandle_t xReturn = NULL; - traceENTER_xTaskGetCurrentTaskHandleCPU( xCoreID ); + traceENTER_xTaskGetCurrentTaskHandleForCore( xCoreID ); if( taskVALID_CORE_ID( xCoreID ) != pdFALSE ) { xReturn = pxCurrentTCBs[ xCoreID ]; } - traceRETURN_xTaskGetCurrentTaskHandleCPU( xReturn ); + traceRETURN_xTaskGetCurrentTaskHandleForCore( xReturn ); return xReturn; } From a8650b99a33cd6fbc557748ef719e0229296676d Mon Sep 17 00:00:00 2001 From: Tony Josi Date: Mon, 23 Oct 2023 14:50:41 +0530 Subject: [PATCH 7/7] Update example cmake project path (#851) * fix build on 64 bit platform * moving sample cmake project to a separate root level dir * moving sample cmake project to a separate root level dir * updating paths for the sample cmake project * rename example folder * use configKERNEL_PROVIDED_STATIC_MEMORY * update comments * update comments * rename folder to examples * fix formatting --- README.md | 2 +- .../cmake_example}/CMakeLists.txt | 4 +-- .../cmake_example}/main.c | 24 -------------- .../sample_configuration}/FreeRTOSConfig.h | 32 ++++++++++++++----- .../sample_configuration}/readme.md | 0 portable/template/portmacro.h | 3 ++ 6 files changed, 30 insertions(+), 35 deletions(-) rename {cmake_example => examples/cmake_example}/CMakeLists.txt (88%) rename {cmake_example => examples/cmake_example}/main.c (74%) rename {sample_configuration => examples/sample_configuration}/FreeRTOSConfig.h (94%) rename {sample_configuration => examples/sample_configuration}/readme.md (100%) diff --git a/README.md b/README.md index 2ef71997237..c6633563f1e 100644 --- a/README.md +++ b/README.md @@ -125,7 +125,7 @@ See the readme file in the ```./portable``` directory for more information. - The ```./include``` directory contains the real time kernel header files. - The ```./sample_configuration``` directory contains a sample `FreeRTOSConfig.h` to help jumpstart a new project. -See the [FreeRTOSConfig.h](sample_configuration/FreeRTOSConfig.h) file for instructions. +See the [FreeRTOSConfig.h](examples/sample_configuration/FreeRTOSConfig.h) file for instructions. ### Code Formatting diff --git a/cmake_example/CMakeLists.txt b/examples/cmake_example/CMakeLists.txt similarity index 88% rename from cmake_example/CMakeLists.txt rename to examples/cmake_example/CMakeLists.txt index 7230120390f..2bb317296e3 100644 --- a/cmake_example/CMakeLists.txt +++ b/examples/cmake_example/CMakeLists.txt @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.15) project(example) -set(FREERTOS_KERNEL_PATH "../") +set(FREERTOS_KERNEL_PATH "../../") # Add the freertos_config for FreeRTOS-Kernel add_library(freertos_config INTERFACE) @@ -13,7 +13,7 @@ target_include_directories(freertos_config ) # Select the heap port. values between 1-4 will pick a heap. -# set(FREERTOS_HEAP "4" CACHE STRING "" FORCE) +set(FREERTOS_HEAP "4" CACHE STRING "" FORCE) # Select the native compile PORT set(FREERTOS_PORT "TEMPLATE" CACHE STRING "" FORCE) diff --git a/cmake_example/main.c b/examples/cmake_example/main.c similarity index 74% rename from cmake_example/main.c rename to examples/cmake_example/main.c index d00aeae7206..bf1717e95aa 100644 --- a/cmake_example/main.c +++ b/examples/cmake_example/main.c @@ -44,12 +44,6 @@ static StaticTask_t exampleTaskTCB; static StackType_t exampleTaskStack[ configMINIMAL_STACK_SIZE ]; -static StaticTask_t xTimerTaskTCB; -static StackType_t uxTimerTaskStack[ configTIMER_TASK_STACK_DEPTH ]; - -static StaticTask_t xIdleTaskTCB; -static StackType_t uxIdleTaskStack[ configMINIMAL_STACK_SIZE ]; - void exampleTask( void * parameters ) { /* Unused parameters. */ @@ -91,21 +85,3 @@ void vApplicationStackOverflowHook( TaskHandle_t xTask, ( void ) xTask; ( void ) pcTaskName; } - -void vApplicationGetTimerTaskMemory( StaticTask_t ** ppxTimerTaskTCBBuffer, - StackType_t ** ppxTimerTaskStackBuffer, - uint32_t * pulTimerTaskStackSize ) -{ - *ppxTimerTaskTCBBuffer = &xTimerTaskTCB; - *ppxTimerTaskStackBuffer = uxTimerTaskStack; - *pulTimerTaskStackSize = configTIMER_TASK_STACK_DEPTH; -} - -void vApplicationGetIdleTaskMemory( StaticTask_t ** ppxIdleTaskTCBBuffer, - StackType_t ** ppxIdleTaskStackBuffer, - uint32_t * pulIdleTaskStackSize ) -{ - *ppxIdleTaskTCBBuffer = &xIdleTaskTCB; - *ppxIdleTaskStackBuffer = uxIdleTaskStack; - *pulIdleTaskStackSize = configMINIMAL_STACK_SIZE; -} diff --git a/sample_configuration/FreeRTOSConfig.h b/examples/sample_configuration/FreeRTOSConfig.h similarity index 94% rename from sample_configuration/FreeRTOSConfig.h rename to examples/sample_configuration/FreeRTOSConfig.h index 43282118f10..32b75bc9d85 100644 --- a/sample_configuration/FreeRTOSConfig.h +++ b/examples/sample_configuration/FreeRTOSConfig.h @@ -118,13 +118,21 @@ * human readable name. Includes the NULL terminator. */ #define configMAX_TASK_NAME_LEN 16 -/* The tick count is held in a variable of type TickType_t. Set - * configUSE_16_BIT_TICKS to 1 to make TickType_t a 16-bit type. Set - * configUSE_16_BIT_TICKS to 0 to make TickType_t either a 32 or 64-bit type - * depending on the architecture. Using a 16-bit type can greatly improve - * efficiency on 8-bit and 16-bit microcontrollers, but at the cost of limiting the - * maximum specifiable block time to 0xffff. */ -#define configUSE_16_BIT_TICKS 0 +/* Time is measured in 'ticks' - which is the number of times the tick interrupt + * has executed since the RTOS kernel was started. + * The tick count is held in a variable of type TickType_t. + * + * configTICK_TYPE_WIDTH_IN_BITS controls the type (and therefore bit-width) of TickType_t: + * + * Defining configTICK_TYPE_WIDTH_IN_BITS as TICK_TYPE_WIDTH_16_BITS causes + * TickType_t to be defined (typedef'ed) as an unsigned 16-bit type. + * + * Defining configTICK_TYPE_WIDTH_IN_BITS as TICK_TYPE_WIDTH_32_BITS causes + * TickType_t to be defined (typedef'ed) as an unsigned 32-bit type. + * + * Defining configTICK_TYPE_WIDTH_IN_BITS as TICK_TYPE_WIDTH_64_BITS causes + * TickType_t to be defined (typedef'ed) as an unsigned 64-bit type. */ +#define configTICK_TYPE_WIDTH_IN_BITS TICK_TYPE_WIDTH_64_BITS /* Set configIDLE_SHOULD_YIELD to 1 to have the Idle task yield to an * application task if there is an Idle priority (priority 0) application task that @@ -388,7 +396,15 @@ /* secureconfigMAX_SECURE_CONTEXTS define the maximum number of tasks that can * call into the secure side of an ARMv8-M chip. Not used by any other ports. */ -#define secureconfigMAX_SECURE_CONTEXTS 5 +#define secureconfigMAX_SECURE_CONTEXTS 5 + +/* Defines the kernel provided implementation of + * vApplicationGetIdleTaskMemory() and vApplicationGetTimerTaskMemory() + * to provide the memory that is used by the Idle task and Timer task respectively. + * The application can provide it's own implementation of + * vApplicationGetIdleTaskMemory() and vApplicationGetTimerTaskMemory() by + * setting configKERNEL_PROVIDED_STATIC_MEMORY to 0 or leaving it undefined. */ +#define configKERNEL_PROVIDED_STATIC_MEMORY 1 /******************************************************************************/ /* Definitions that include or exclude functionality. *************************/ diff --git a/sample_configuration/readme.md b/examples/sample_configuration/readme.md similarity index 100% rename from sample_configuration/readme.md rename to examples/sample_configuration/readme.md diff --git a/portable/template/portmacro.h b/portable/template/portmacro.h index 96b400c15ea..4e4aa934d43 100644 --- a/portable/template/portmacro.h +++ b/portable/template/portmacro.h @@ -38,6 +38,9 @@ typedef unsigned char UBaseType_t; #elif ( configTICK_TYPE_WIDTH_IN_BITS == TICK_TYPE_WIDTH_32_BITS ) typedef uint32_t TickType_t; #define portMAX_DELAY ( TickType_t ) 0xffffffffUL +#elif ( configTICK_TYPE_WIDTH_IN_BITS == TICK_TYPE_WIDTH_64_BITS ) + typedef uint64_t TickType_t; + #define portMAX_DELAY ( TickType_t ) 0xffffffffffffffffULL #else #error configTICK_TYPE_WIDTH_IN_BITS set to unsupported tick type width. #endif