AnsweredAssumed Answered

i.MX RT1051 + mbedTLS + TLS 1.2 + DCP

Question asked by Mathieu Borderé on Jul 26, 2019
Latest reply on Jul 29, 2019 by jeremyzhou

Hi,

 

I'm trying to setup a TLS 1.2 connection with mbedTLS on a i.MX RT1051 with Hardware/DCP accelerated AES128 and SHA256.

For this to work I need to setup the mbedTLS heap allocator to use non-cached memory that can be accessed by the DCP.

 

When I place the mbedTLS heap in DTCM memory, I'm able to setup a TLS connection and all seems to work fine, however when I move the mbedTLS heap to non-cached SDRAM I fail to setup a TLS connection.

 

Non-cached SDRAM is setup like this in the MPU

/* Region 9 setting, set last 2MB of SDRAM can't be accessed by cache, local variables which are not expected to be accessed by cache can be put here */
    MPU->RBAR = ARM_MPU_RBAR(9, 0x81E00000U);
    MPU->RASR = ARM_MPU_RASR(0, ARM_MPU_AP_FULL, 1, 0, 0, 0, 0, ARM_MPU_REGION_SIZE_2MB);

 

Is this the correct setting?

Outcomes