From 0eeb0097d552707ddd67f4e7f0434cf8c0fae846 Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 12:55:02 -0800 Subject: [PATCH 01/10] [8.6] Suppress declaration without definitions warnings This is expected from the portable header as it is implemented by the port. --- MISRA.md | 3 +++ include/portable.h | 36 ++++++++++++++++++++++++++++++------ 2 files changed, 33 insertions(+), 6 deletions(-) diff --git a/MISRA.md b/MISRA.md index 87ff4cbcd6c..f2008328c0c 100644 --- a/MISRA.md +++ b/MISRA.md @@ -51,6 +51,9 @@ _Ref 8.6.1_ - This rule prohibits an identifier with external linkage to have multiple definitions or no definition. FreeRTOS hook functions are implemented in the application and therefore, have no definition in the Kernel code. + - Port layer function declarations are provided without corresponding + implementations to provide for ease of porting to a device. These definitions + cannot be implemented until a port is selected. #### Rule 11.1 MISRA C:2012 Rule 11.1: Conversions shall not be performed between a pointer to diff --git a/include/portable.h b/include/portable.h index 68e11e79311..477eebb84f6 100644 --- a/include/portable.h +++ b/include/portable.h @@ -175,20 +175,44 @@ typedef struct xHeapStats * terminated by a HeapRegions_t structure that has a size of 0. The region * with the lowest start address must appear first in the array. */ +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ void vPortDefineHeapRegions( const HeapRegion_t * const pxHeapRegions ) PRIVILEGED_FUNCTION; -/* - * Returns a HeapStats_t structure filled with information about the current - * heap state. - */ -void vPortGetHeapStats( HeapStats_t * pxHeapStats ); - /* * Map to the memory management routines required for the port. */ +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ void * pvPortMalloc( size_t xWantedSize ) PRIVILEGED_FUNCTION; +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ void * pvPortCalloc( size_t xNum, size_t xSize ) PRIVILEGED_FUNCTION; +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ +void vPortFree( void * pv ) PRIVILEGED_FUNCTION; +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ +void vPortInitialiseBlocks( void ) PRIVILEGED_FUNCTION; +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ +size_t xPortGetFreeHeapSize( void ) PRIVILEGED_FUNCTION; +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ +size_t xPortGetMinimumEverFreeHeapSize( void ) PRIVILEGED_FUNCTION; +/* MISRA Ref 8.6.1 [External linkage] */ +/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ +/* coverity[misra_c_2012_rule_8_6_violation] */ +void xPortResetHeapMinimumEverFreeHeapSize( void ) PRIVILEGED_FUNCTION; + size_t xSize ) PRIVILEGED_FUNCTION; void vPortFree( void * pv ) PRIVILEGED_FUNCTION; void vPortInitialiseBlocks( void ) PRIVILEGED_FUNCTION; size_t xPortGetFreeHeapSize( void ) PRIVILEGED_FUNCTION; From edbeef2a72259a25087bdac6f8f3aa7d54380cfd Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 13:20:19 -0800 Subject: [PATCH 02/10] [21.3] Document unsupressed deviation Deviations which are unsupressed should be documented for user awareness. --- MISRA.md | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/MISRA.md b/MISRA.md index f2008328c0c..67fcde7196a 100644 --- a/MISRA.md +++ b/MISRA.md @@ -146,3 +146,36 @@ _Ref 21.6.1_ - The Standard Library function snprintf is used in vTaskListTasks and vTaskGetRunTimeStatistics APIs, both of which are utility functions only and are not considered part of core kernel implementation. + +### Unsupressed Deviations + +Certain deviating code is left unsurpressed for awarness. This code should +not be considered for usage in MISRA compliant applications. These violations +will be reported when audited by a MISRA-checking static analysis tool. + +#### Rule 21.3 + +MISRA C-2012 Rule 21.3: The memory allocation and deallocation functions of + shall not be used. + +_Ref 21.3_ + - Heap memory solutions utilize pvPortMalloc/vPortFree to provide heap + memory for dynamic object allocation. These functions may rely upon + the malloc/free of the underlying port. Static allocation is reccomended + for MISRA compliant applications. + + Affected Files: + - portable/MemMang/heap_*.c + +#### Rule 21.6 + +MISRA C-2012 Rule 21.6: The Standard Library input/output functions shall not +be used. + +_Ref 21.6.1_ + - The Standard Library function printf is used in examples to provide a + simple getting started demonstration. This example is not considered part + of the kernel implementation. + + Affected Files: + - examples/cmake_example/main.c \ No newline at end of file From 1688966a946851ac7ae8de6e16b3eae57a0cf98b Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 13:39:41 -0800 Subject: [PATCH 03/10] [2.2] Disclose dead code warning --- MISRA.md | 9 +++++++++ tasks.c | 3 +++ 2 files changed, 12 insertions(+) diff --git a/MISRA.md b/MISRA.md index 67fcde7196a..abe2bf92c17 100644 --- a/MISRA.md +++ b/MISRA.md @@ -18,7 +18,16 @@ with ( Assuming rule 8.4 violation; with justification in point 1 ): grep 'MISRA Ref 8.4.1' . -rI ``` +#### Dir 2.2 + +MISRA C:2012 Dir 2.2: There shall be no dead code. + +_Ref 2.2_ + - `vPortEndScheduler` is erroneously determined to be dead code due to + simplified verification port. + #### Dir 4.7 + MISRA C:2012 Dir 4.7: If a function returns error information, then that error information shall be tested. diff --git a/tasks.c b/tasks.c index c596c475f8c..b570600a306 100644 --- a/tasks.c +++ b/tasks.c @@ -3839,6 +3839,9 @@ void vTaskEndScheduler( void ) /* This function must be called from a task and the application is * responsible for deleting that task after the scheduler is stopped. */ + /* MISRA Ref 2.2 [No dead code] */ + /* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#dir-22 */ + /* coverity[misra_c_2012_directive_2_2_violation] */ vPortEndScheduler(); traceRETURN_vTaskEndScheduler(); From 501ce1fadc7615f3789c4c114835a4b0c80c8e8d Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 13:43:34 -0800 Subject: [PATCH 04/10] [2.1] Justify unreachable code in example --- MISRA.md | 31 +++++++++++++++++++++++-------- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/MISRA.md b/MISRA.md index abe2bf92c17..6a1a6402fd7 100644 --- a/MISRA.md +++ b/MISRA.md @@ -18,14 +18,6 @@ with ( Assuming rule 8.4 violation; with justification in point 1 ): grep 'MISRA Ref 8.4.1' . -rI ``` -#### Dir 2.2 - -MISRA C:2012 Dir 2.2: There shall be no dead code. - -_Ref 2.2_ - - `vPortEndScheduler` is erroneously determined to be dead code due to - simplified verification port. - #### Dir 4.7 MISRA C:2012 Dir 4.7: If a function returns error information, then that error @@ -162,6 +154,29 @@ Certain deviating code is left unsurpressed for awarness. This code should not be considered for usage in MISRA compliant applications. These violations will be reported when audited by a MISRA-checking static analysis tool. +#### Dir 2.1 + +MISRA C:2012 Dir 2.1: A project shall not contain unreachable code + +_Ref 2.1_ + - Simplified example contains unreachable code for demonstration of + freertos scheduler. A production implemenation should not contain + this. + + Affected Files: + - examples/cmake_example/main.c + +#### Dir 2.2 + +MISRA C:2012 Dir 2.2: There shall be no dead code. + +_Ref 2.2_ + - `vPortEndScheduler` is erroneously determined to be dead code due to + simplified verification port. + + Affected Files: + - tasks.c + #### Rule 21.3 MISRA C-2012 Rule 21.3: The memory allocation and deallocation functions of From ce00f074dc70b189b6f3b37ce60786af14881fc7 Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 14:00:50 -0800 Subject: [PATCH 05/10] [17.12] Add addressing operator to callback function This is required to disambiguate a function call and a function to-be called --- event_groups.c | 4 ++-- examples/cmake_example/main.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/event_groups.c b/event_groups.c index 7c5c15db792..c69b9655766 100644 --- a/event_groups.c +++ b/event_groups.c @@ -511,7 +511,7 @@ traceENTER_xEventGroupClearBitsFromISR( xEventGroup, uxBitsToClear ); traceEVENT_GROUP_CLEAR_BITS_FROM_ISR( xEventGroup, uxBitsToClear ); - xReturn = xTimerPendFunctionCallFromISR( vEventGroupClearBitsCallback, ( void * ) xEventGroup, ( uint32_t ) uxBitsToClear, NULL ); + xReturn = xTimerPendFunctionCallFromISR( &vEventGroupClearBitsCallback, ( void * ) xEventGroup, ( uint32_t ) uxBitsToClear, NULL ); traceRETURN_xEventGroupClearBitsFromISR( xReturn ); @@ -823,7 +823,7 @@ traceENTER_xEventGroupSetBitsFromISR( xEventGroup, uxBitsToSet, pxHigherPriorityTaskWoken ); traceEVENT_GROUP_SET_BITS_FROM_ISR( xEventGroup, uxBitsToSet ); - xReturn = xTimerPendFunctionCallFromISR( vEventGroupSetBitsCallback, ( void * ) xEventGroup, ( uint32_t ) uxBitsToSet, pxHigherPriorityTaskWoken ); + xReturn = xTimerPendFunctionCallFromISR( &vEventGroupSetBitsCallback, ( void * ) xEventGroup, ( uint32_t ) uxBitsToSet, pxHigherPriorityTaskWoken ); traceRETURN_xEventGroupSetBitsFromISR( xReturn ); diff --git a/examples/cmake_example/main.c b/examples/cmake_example/main.c index 96a2abfe13c..4b7ad5c5f29 100644 --- a/examples/cmake_example/main.c +++ b/examples/cmake_example/main.c @@ -69,7 +69,7 @@ int main( void ) ( void ) printf( "Example FreeRTOS Project\n" ); - ( void ) xTaskCreateStatic( exampleTask, + ( void ) xTaskCreateStatic( &exampleTask, "example", configMINIMAL_STACK_SIZE, NULL, From 34d51f74b781991190c9ac0c5916edbc923926fd Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 14:05:51 -0800 Subject: [PATCH 06/10] [4.12] Explain deviation for dynamic allocation --- MISRA.md | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/MISRA.md b/MISRA.md index 6a1a6402fd7..9c834010a76 100644 --- a/MISRA.md +++ b/MISRA.md @@ -154,7 +154,7 @@ Certain deviating code is left unsurpressed for awarness. This code should not be considered for usage in MISRA compliant applications. These violations will be reported when audited by a MISRA-checking static analysis tool. -#### Dir 2.1 +#### Rule 2.1 MISRA C:2012 Dir 2.1: A project shall not contain unreachable code @@ -166,23 +166,22 @@ _Ref 2.1_ Affected Files: - examples/cmake_example/main.c -#### Dir 2.2 +#### Rule 2.2 MISRA C:2012 Dir 2.2: There shall be no dead code. _Ref 2.2_ - `vPortEndScheduler` is erroneously determined to be dead code due to - simplified verification port. + the use of a simplified verification port. Affected Files: - tasks.c -#### Rule 21.3 +#### Dir 4.12 -MISRA C-2012 Rule 21.3: The memory allocation and deallocation functions of - shall not be used. +MISRA C:2012 Dir 4.12: Dynamic allocation shall not be used -_Ref 21.3_ +_Ref 4.12_ - Heap memory solutions utilize pvPortMalloc/vPortFree to provide heap memory for dynamic object allocation. These functions may rely upon the malloc/free of the underlying port. Static allocation is reccomended @@ -191,6 +190,17 @@ _Ref 21.3_ Affected Files: - portable/MemMang/heap_*.c +#### Rule 21.3 + +MISRA C-2012 Rule 21.3: The memory allocation and deallocation functions of + shall not be used. + +_Ref 21.3_ + - See justification from Directive 4.12 + + Affected Files: + - portable/MemMang/heap_*.c + #### Rule 21.6 MISRA C-2012 Rule 21.6: The Standard Library input/output functions shall not From 47d94cb6b03352c07d213fc91003a83421455ece Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 14:15:51 -0800 Subject: [PATCH 07/10] [8.6] Remove suppression, instead explain reporting --- MISRA.md | 28 +++++++++++++++++++++++----- include/portable.h | 33 ++++++--------------------------- 2 files changed, 29 insertions(+), 32 deletions(-) diff --git a/MISRA.md b/MISRA.md index 9c834010a76..8acb3686682 100644 --- a/MISRA.md +++ b/MISRA.md @@ -52,9 +52,6 @@ _Ref 8.6.1_ - This rule prohibits an identifier with external linkage to have multiple definitions or no definition. FreeRTOS hook functions are implemented in the application and therefore, have no definition in the Kernel code. - - Port layer function declarations are provided without corresponding - implementations to provide for ease of porting to a device. These definitions - cannot be implemented until a port is selected. #### Rule 11.1 MISRA C:2012 Rule 11.1: Conversions shall not be performed between a pointer to @@ -150,10 +147,20 @@ _Ref 21.6.1_ ### Unsupressed Deviations -Certain deviating code is left unsurpressed for awarness. This code should -not be considered for usage in MISRA compliant applications. These violations +Certain deviating code is left unsurpressed for awarness. These violations will be reported when audited by a MISRA-checking static analysis tool. +Some of these unsuppressed exceptions correspond to example code provided +either for demonstration or verification of the FreeRTOS kernel. This code +is not considered part of the kernel implemenation and should not be used +in an application. + +Other unsupressed violations are left present in the kernel implementation +as implementations, code, or other missing functionality being flagged for +violations will be present with the porting layer provided by the +application. The presence of these errors after providing a port indicates +a valid MISRA issue. + #### Rule 2.1 MISRA C:2012 Dir 2.1: A project shall not contain unreachable code @@ -190,6 +197,17 @@ _Ref 4.12_ Affected Files: - portable/MemMang/heap_*.c + +#### Rule 8.6 + +MISRA C:2012 Rule 8.6: An identifier with external linkage shall have exactly +one external definition. + +_Ref 8.6.1_ + - Port layer function declarations are provided without corresponding + implementations to provide for ease of porting to a device. These definitions + cannot be implemented until a port is selected. + #### Rule 21.3 MISRA C-2012 Rule 21.3: The memory allocation and deallocation functions of diff --git a/include/portable.h b/include/portable.h index 477eebb84f6..9050a851dea 100644 --- a/include/portable.h +++ b/include/portable.h @@ -180,39 +180,18 @@ typedef struct xHeapStats /* coverity[misra_c_2012_rule_8_6_violation] */ void vPortDefineHeapRegions( const HeapRegion_t * const pxHeapRegions ) PRIVILEGED_FUNCTION; +/* + * Returns a HeapStats_t structure filled with information about the current + * heap state. + */ +void vPortGetHeapStats( HeapStats_t * pxHeapStats ); + /* * Map to the memory management routines required for the port. */ -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ void * pvPortMalloc( size_t xWantedSize ) PRIVILEGED_FUNCTION; -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ void * pvPortCalloc( size_t xNum, size_t xSize ) PRIVILEGED_FUNCTION; -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ -void vPortFree( void * pv ) PRIVILEGED_FUNCTION; -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ -void vPortInitialiseBlocks( void ) PRIVILEGED_FUNCTION; -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ -size_t xPortGetFreeHeapSize( void ) PRIVILEGED_FUNCTION; -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ -size_t xPortGetMinimumEverFreeHeapSize( void ) PRIVILEGED_FUNCTION; -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ -void xPortResetHeapMinimumEverFreeHeapSize( void ) PRIVILEGED_FUNCTION; - size_t xSize ) PRIVILEGED_FUNCTION; void vPortFree( void * pv ) PRIVILEGED_FUNCTION; void vPortInitialiseBlocks( void ) PRIVILEGED_FUNCTION; size_t xPortGetFreeHeapSize( void ) PRIVILEGED_FUNCTION; From 82c80e631d0e45351c4c169f651dfef1a8013f3b Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 14:23:38 -0800 Subject: [PATCH 08/10] Fix spelling, formatting --- MISRA.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/MISRA.md b/MISRA.md index 8acb3686682..5016e7b2778 100644 --- a/MISRA.md +++ b/MISRA.md @@ -145,19 +145,19 @@ _Ref 21.6.1_ vTaskGetRunTimeStatistics APIs, both of which are utility functions only and are not considered part of core kernel implementation. -### Unsupressed Deviations +### Unsuppressed Deviations -Certain deviating code is left unsurpressed for awarness. These violations +Certain deviating code is left unsuppressed for awareness. These violations will be reported when audited by a MISRA-checking static analysis tool. Some of these unsuppressed exceptions correspond to example code provided either for demonstration or verification of the FreeRTOS kernel. This code -is not considered part of the kernel implemenation and should not be used +is not considered part of the kernel implementation and should not be used in an application. -Other unsupressed violations are left present in the kernel implementation +Other unsuppressed violations are left present in the kernel implementation as implementations, code, or other missing functionality being flagged for -violations will be present with the porting layer provided by the +violations will be present with the porting layer provided by the application. The presence of these errors after providing a port indicates a valid MISRA issue. @@ -167,7 +167,7 @@ MISRA C:2012 Dir 2.1: A project shall not contain unreachable code _Ref 2.1_ - Simplified example contains unreachable code for demonstration of - freertos scheduler. A production implemenation should not contain + FreeRTOS scheduler. A production implementation should not contain this. Affected Files: @@ -191,7 +191,7 @@ MISRA C:2012 Dir 4.12: Dynamic allocation shall not be used _Ref 4.12_ - Heap memory solutions utilize pvPortMalloc/vPortFree to provide heap memory for dynamic object allocation. These functions may rely upon - the malloc/free of the underlying port. Static allocation is reccomended + the malloc/free of the underlying port. Static allocation is recommended for MISRA compliant applications. Affected Files: @@ -225,9 +225,9 @@ MISRA C-2012 Rule 21.6: The Standard Library input/output functions shall not be used. _Ref 21.6.1_ - - The Standard Library function printf is used in examples to provide a + - The Standard Library function `printf` is used in examples to provide a simple getting started demonstration. This example is not considered part of the kernel implementation. Affected Files: - - examples/cmake_example/main.c \ No newline at end of file + - examples/cmake_example/main.c From 9a39b1d39c3699a91990849acba7155f767be0a0 Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Fri, 20 Feb 2026 14:30:22 -0800 Subject: [PATCH 09/10] Remove two suppressions which I forgot --- include/portable.h | 3 --- tasks.c | 3 --- 2 files changed, 6 deletions(-) diff --git a/include/portable.h b/include/portable.h index 9050a851dea..68e11e79311 100644 --- a/include/portable.h +++ b/include/portable.h @@ -175,9 +175,6 @@ typedef struct xHeapStats * terminated by a HeapRegions_t structure that has a size of 0. The region * with the lowest start address must appear first in the array. */ -/* MISRA Ref 8.6.1 [External linkage] */ -/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */ -/* coverity[misra_c_2012_rule_8_6_violation] */ void vPortDefineHeapRegions( const HeapRegion_t * const pxHeapRegions ) PRIVILEGED_FUNCTION; /* diff --git a/tasks.c b/tasks.c index b570600a306..c596c475f8c 100644 --- a/tasks.c +++ b/tasks.c @@ -3839,9 +3839,6 @@ void vTaskEndScheduler( void ) /* This function must be called from a task and the application is * responsible for deleting that task after the scheduler is stopped. */ - /* MISRA Ref 2.2 [No dead code] */ - /* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#dir-22 */ - /* coverity[misra_c_2012_directive_2_2_violation] */ vPortEndScheduler(); traceRETURN_vTaskEndScheduler(); From 98ffa0d89242c769e796eaf0d997a5975b3cfc09 Mon Sep 17 00:00:00 2001 From: Kody Stribrny Date: Mon, 23 Feb 2026 08:36:28 -0800 Subject: [PATCH 10/10] Suppress false null dereference Coverity provides a false positive of pxQueueSetContainer being null. --- queue.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/queue.c b/queue.c index a967839de67..25613bf3f8b 100644 --- a/queue.c +++ b/queue.c @@ -3343,6 +3343,8 @@ BaseType_t xQueueIsQueueFullFromISR( const QueueHandle_t xQueue ) configASSERT( pxQueueSetContainer ); /* LCOV_EXCL_BR_LINE */ configASSERT( pxQueueSetContainer->uxMessagesWaiting < pxQueueSetContainer->uxLength ); + /* pxQueue->pxQueueSetContainer is verified to be non-null by caller. */ + /* coverity[dereference] */ if( pxQueueSetContainer->uxMessagesWaiting < pxQueueSetContainer->uxLength ) { const int8_t cTxLock = pxQueueSetContainer->cTxLock;