Menu ▾ ▴

#173 StaticTask_t vs. TCB_t mismatch

v1.0 (example)
closed-out-of-date
Richard
None
5
2018-07-06
2018-07-06
No

The StaticTask_t seems to be incongruent to TCB_t whenever INCLUDE_xTaskAbortDelay == 1 -- and configSUPPORT_STATIC_ALLOCATION == 1, obviously.
StaticTask_t doesn't grow accordingly. sizeof(...) returns 84 bytes vs 88 bytes on a STM32L4 MCU. This leads to an out-of-bounds memory write -- and to a system crash in my case. (FreeRTOS v. 9.0.0)

Adding

#if( INCLUDE_xTaskAbortDelay == 1 )
        uint8_t         uxDummy21;
    #endif

to

struct xSTATIC_TCB

fixes the situation for me. Please have a look into this. Thanks.

Discussion

  • Philipp Legrum

    Philipp Legrum - 2018-07-06

    I've just noticed that this is fixed in FreeRTOS 10.

     
  • Richard Barry

    Richard Barry - 2018-07-06
    • status: open --> closed-out-of-date
     

Log in to post a comment.