Hello,
I'm working on a L2Boot on EVK-XRT1040. I'm testing the possibility to manage two application images without swapping them.
I know I have to use the three IOMUXC registers, IOMUXC_GPR30, IOMUXC_GPR31, and IOMUXC_GPR32 to create and offset to the application.
My first temptative was a jump without offset, it run properly.
The second temptative was the jump with an offset, and here I have the problem.
This is my flash design:
L2_Boot: 0x6000_0000 - 0x6001_0000
App1: 0x6002_0000 - 0x6004_0000
App2: 0x6006_0000 - 0x6008_0000
Both App1 and App2 are compiled in the range of App1 (0x6002_0000 - 0x6004_0000)
App1 and App2 are the same code, they are just a simple blinking led example.
First temptative - jump with no offset
I loaded the App at address 0x6002_0000, this is the code of my L2 boot at the jump:

It works properly, after the jump the debugger stops to follow the code (no errors appear) and the App blinking led starts to run as expected.
This is good.
Second temptative - jump with offset
Starting from a mass erase, I loaded the same App used previously (compiled at address 0x6002_0000) at address 0x6006_0000, I defined the offset and relative regions (setting IOMUX_GPRx). This is the code:

In this case the jump to App doesn't run as expected , I mean when the debugger enters the farewellBootloader() it gives me the following error and the blinking led example doesn't start.

What is wrong in my jump with offset?
Thank you for your support