configENABLE_TRUSTZONE == 0

Hi !

I have tried to compile LPC55S69 port when on nonsecure part rtos used without any secure context allocation. E.g- configENABLE_TRUSTZONE == 0

But in portasm this flag is not used and xSecureContext is still referenced.

portasm.c:232: undefined reference to `xSecureContext’

Is any idea how to disable this in correct way ?

Regards,
Eugene

Hi Eugene,

If you do not want to use TrustZone, you need to use ARM_CM33_NTZ port: https://github.com/FreeRTOS/FreeRTOS-Kernel/tree/master/portable/GCC/ARM_CM33_NTZ/non_secure

This section provides more details on how to use FreeRTOS without TrustZone support:https://www.freertos.org/2020/04/using-freertos-on-armv8-m-microcontrollers.html#FREERTOS_WITHOUT_TRUSTZONE

Thanks,
Gaurav

Hi Gaurav !

Looks like feature is not fully supported under #ifdef configENABLE_TRUSTZONE flag.
I should take other portasm.c from different folder.
Basically it mean RTOS what is running on nonsecure side without any communication with secure side.
Is this so ?

Regards,
Eugene

Looks like feature is not fully supported under #ifdef configENABLE_TRUSTZONE flag.

If you do not want to use TrustZone support (i.e. want to have the complete memory space as non-secure), you need to do the following two things:

  • Build FreeRTOS with configENABLE_TRUSTZONE set to zero in FreeRTOSConfig.h file.
  • Use ARM_CM23_NTZ or ARM_CM33_NTZ port files depending on whether the target hardware is an ARM Cortex-M23 or an ARM Cortex-M33.

As I mentioned above, it is described in detail here: https://www.freertos.org/2020/04/using-freertos-on-armv8-m-microcontrollers.html#FREERTOS_WITHOUT_TRUSTZONE

Basically it mean RTOS what is running on nonsecure side without any communication with secure side.
Is this so ?

Yes.

Thanks.