i.MX93: Cortex M33 not booting from U-Boot / Linux

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

i.MX93: Cortex M33 not booting from U-Boot / Linux

1,352 Views
Niebel-TQ
Contributor IV

We are about to port our starter kits to the latest SDK (25.03.00). As the very first step we try to get simple hello world demo running. We are facing two problems:

  1. Starting demo from U-Boot using `bootaux`:  binary can be loaded and started. Feedback is that M33 is running. No output from Debug-UART
  2. Starting demo from debugger (J-Link v8.32) while Cortex-A55 is running (U-Boot):  debugger is not able to connect to M33:

```

Device "MIMX9351_M33" selected.


Connecting to target via JTAG
ConfigTargetSettings() start
ConfigTargetSettings() end - Took 30us
InitTarget() start
InitTarget() end - Took 7.74ms
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x0892801D, IRLen: 04, JTAG-DP
Failed to power up DAP
Connect failed. Resetting via Reset pin and trying again.
ConfigTargetSettings() start
ConfigTargetSettings() end - Took 26us
InitTarget() start
DAP: Could not power-up system power domain.
InitTarget() end - Took 13.2ms
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x0892801D, IRLen: 04, JTAG-DP
Failed to power up DAP
Error occurred: Could not connect to the target device.
```

(The JTAG works, when setting the board to LP Boot via Serial Downloader we are able to start the GDB server and debug the hello world demo)

U-Boot: v2024.04 from uboot-imx
TF-A: lf-2.10 without optee

 

 

0 Kudos
Reply
13 Replies

1,340 Views
Chavira
NXP TechSupport
NXP TechSupport

HI @Niebel-TQ!

Thank you for contacting NXP Support!

 

I tried by my side and is working good.

Chavira_0-1747161203441.png

Chavira_1-1747161223959.png

 

What BSP version do you have?

Are you using the EVK board?

 

I recommend to check our AN14120 to download the required patch to debug the processor.

 

Best Regards!

Chavira

 

0 Kudos
Reply

1,318 Views
Niebel-TQ
Contributor IV
Thank you.

BSP: based on current meta-freescale scarthgap
Board: Custum board
Current Version of AN14120 does not mention the patch for JLink. Also for recent versions of JLink the patch is not applicable any longer
0 Kudos
Reply

1,304 Views
Niebel-TQ
Contributor IV
Just an Update:

Running the hello world demo from current SDK (25.03.00) with bootaux from U-Boot is possible with older BSP based on:
u-boot-imx v2023.04 / older atf-imx 2.10 / ELE firmware version 1.1.0-17eafba6

The J-Link debugger can attach to M33 when U-Boot is loaded under the above mentioned software setup. Starting a program from J-Link does only work after several tries
0 Kudos
Reply

1,300 Views
Chavira
NXP TechSupport
NXP TechSupport

HI @Niebel-TQ!

I tried by my side with the BSP scarthgap 6.6.36 with the iMX93-EVK and is working without problems.

 

Can you double check your board?

That kind of cases it is very difficult for us to support since we don't have your board to try by our side.

 

Do you Customize the device tree according to your hardware?

0 Kudos
Reply

1,259 Views
Niebel-TQ
Contributor IV

Hi and thanks for the reply.

It seems like having two problems:

1) Booting Cortex M33 from Linux / U-Boot: works with older Versions but not with current versions. Seems to be Software related. We investigate this. Devicetree is adjusted to our board (Can start and use RPMSG demo and NPU firmware)

2) Debugging with JLink: Seems to be an Issue for i.MX93 (the JLink works for sure, starting downloaded software does not work stable.) You mentioned a Patch that contains special crafted init / reset sequences. This patch does not work with newer JLink releases. There is a hint in SEGGER knowledge base regarding special reset sequence but no detail. Any help how to get a working debugging environment for Cortex M33?

0 Kudos
Reply

1,251 Views
Chavira
NXP TechSupport
NXP TechSupport

HI @Niebel-TQ!

 

Try Append "clk_ignore_unused" in u-boot "mmcargs" env, before booting linux.

The patch was included in the MCUXPRESSO INSTALLER V25.

 

I tried several times debug the iMX93-EVK and is working fine.

 

 

0 Kudos
Reply

1,224 Views
Niebel-TQ
Contributor IV

1) The "clk_ignore_unused" is in the kernel command line if we activated the M33 im U-Boot. (Works with U-Boot 2023.04 and older TF-A + older Edgelock firmware). Try to find the cause, wy M33 does not start with newer versions of said components - neither with bootaux nor with remote_proc. As I said, we debug this. Also in this case the M33 cannot be seen from JTAG

2) Regarding JLINK: What version is known to work for debugging? As i wrote the i.MX93 patch from NXP does not apply to newer JLink Software versions from SEGGER but contains special handling for Reset / Initialisation. The SEGGER knowledge base writes about problems with Reset for M33: https://kb.segger.com/NXP_i.MX_93



 

 

 

0 Kudos
Reply

1,210 Views
Niebel-TQ
Contributor IV

Hi,


so we found the issue for M33 not booting with newer versions. Wenn extending the board support for i.MX91 we lost M33 initialisation in SPL. Thank you for supporting

Second issue remains: JLink / Debugging. Any update to this topic?

 

 

0 Kudos
Reply

1,191 Views
Chavira
NXP TechSupport
NXP TechSupport

Hi @Niebel-TQ!

 

Try updating the firmware of your J-link.

 

At the moment I am using the MCU-LINK PRO with Segger firmware and is working without problems in iMX93-EVK board with the latest pre-compiled image.

I will try using Segger JLink Pro but I am waiting for the same result.

 

Best Regards!

Chavira

 

 

 

0 Kudos
Reply

1,112 Views
Niebel-TQ
Contributor IV

JLink Firmware is up to date. Debugging under Linux not possible. 
OS: Ubuntu 2024.04
SEGGER: V8.32
SDK: 25.03 from github

Expectation: programm can be loaded / started / debugged with gdb / jlink gdbserver

Issue: gdb connects and loads to target, running / debugging not stable.

With Ubuntu 2022.04 / SEGGER J-Link V7.62c with NXP Patch debugging is possible

 

 

 

 

 

0 Kudos
Reply

1,099 Views
Chavira
NXP TechSupport
NXP TechSupport

Hi @Niebel-TQ!

I am tried again by my side in the evk board and the problem is not happening.

I am using ubuntu 22.04 and SDK 25 with the latest BSP version (6.12)

Chavira_0-1747840896444.png

 

Chavira_1-1747840935354.png

Chavira_2-1747840944704.png

 

Best Regards!

Chavira

0 Kudos
Reply

1,093 Views
Niebel-TQ
Contributor IV
Hello, thank you for answering. What version of SEGGER JLink package is in use on your side?
0 Kudos
Reply

1,079 Views
Chavira
NXP TechSupport
NXP TechSupport

HI @Niebel-TQ!

 

Unfortunately at the moment I don't have J-LINK to test by my side I have mentioned that I am using MCU-LINK PRO with Segger firmware.

 

 

0 Kudos
Reply