This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

LESC initialization on FreeRTOS

Hello -

We are also bumping into the problem described here, where it is not possible to initialize LESC when BLE is initialized from a FreeRTOS task. The nrf_stack_info_overflowed() function returns true, which causes the LESC initialization to terminate early with an error code. I believe that the nrf_stack_info_overflowed() function should not even be called when LESC is being initialized from a FreeRTOS task because the stack values are not relevant in this context. Searching for clues, I found this FreeRTOS commit, which suggests the same.

We are using the 15.3.0 SDK on a nRF52840-DK board. The 16.0.0 SDK has the same issue. We are linking against the no-interrupts version of the cc310 library, thought I don't believe that is relevant to this specific failure. In our sdk_config.h file we set both NRF_CRYPTO_RNG_STATIC_MEMORY_BUFFERS_ENABLED and NRF_CRYPTO_RNG_AUTO_INIT_ENABLED to 1. If I comment out the call to nrf_stack_info_overflowed(), the LESC initialization sequence completes without any errors.

Is there a workaround for this issue that doesn't require changing the SDK code? In other words, is there a way to enable LESC with Numeric Comparison when BLE is initialized from a FreeRTOS task?

Best regards,

Brian

Parents
  • Hi. 

    What you explained in your questions seems to be correct.

    Is there a workaround for this issue that doesn't require changing the SDK code?

    I'm afraid that we don't have any workaround other than changing the SDK code for now (commenting out the nrf_stack_info_overflowed()).
    I'll report this internally to our developers, and update the ticket if I get any more information.

    Best regards, 
    Joakim

Reply
  • Hi. 

    What you explained in your questions seems to be correct.

    Is there a workaround for this issue that doesn't require changing the SDK code?

    I'm afraid that we don't have any workaround other than changing the SDK code for now (commenting out the nrf_stack_info_overflowed()).
    I'll report this internally to our developers, and update the ticket if I get any more information.

    Best regards, 
    Joakim

Children
Related