Is there any example for RT1020 Code Protection of external FLASH?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Is there any example for RT1020 Code Protection of external FLASH?

901 Views
matejgutman
Contributor I

I'm about to try out RT1020 MCU. I've been looking into MIMXRT1020-EV for a start. After importing SDK, I've noticed 'evkmimxrt1020_flashloader' example.

As far as I understand, there is an option to encrypt an image and load it into external FLASH and store the KEY into RT1020 to decrypt on the fly and execute the code.

- Is the procedure on how to encrypt the FLASH, set the key in RT1020 device described anywhere? The 'evkmimxrt1020_flashloader' does not contain any documentation, as far as I can see.

- Is there any performance penalty when using encrypted image?

Best regards,

Matej

0 Kudos
2 Replies

657 Views
matejgutman
Contributor I

Hello Victor,

thank you a lot, I will look at it. When I will test on EVK, I might re-open this issue if needed. 

Best regards,

Matej

0 Kudos

657 Views
victorjimenez
NXP TechSupport
NXP TechSupport

Hello Matej,

Is the procedure on how to encrypt the FLASH, set the key in RT1020 device described anywhere? The 'evkmimxrt1020_flashloader' does not contain any documentation, as far as I can see.

Yes, you need to request access to the security application note (link). This document contains the information that you are looking for.

I would also recommend you to take a look at the following tool that one of my co-workes made (link).

Is there any performance penalty when using an encrypted image?

According to our local testing with BEE on I.MXRT1020 there is a significant difference in performance Encrypted XIP and Normal XIP. Encrypted XIP is about 20-30% slower.

I-Cache or D-Cache together with FlexSPI prefetch buffer feature on can significantly help to reduce this Encrypted XIP performance dropout. In this case when Caches and FlexSPI prefetch buffer feature on there is no performance difference notable. But, of course, results with Caches on are code style dependent.


Have a great day,
TIC

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos