Hi,
We are facing difficulties trying to boot u-boot on imx6 using JTAG.
We were able to initialise and check the RAM access. We're also able to load u-boot. But we are still struggling to execute it.
Our Setup
Board: Nitrogen6_max from Boundary Devices
Debugger: J-Link plus from Segger
Software: OpenOCD V 0.9.0
U-boot: compiled from Android release of boundary-imx-kk4.4.3_2.0.0-ga
Our steps:
1. Start the board in USB boot mode.
2. enter the following command in one terminal to start jtag emulator
$ sudo openocd -f ./bd_n6max.cfg
# see attachment for bd_n6max.cfg
3. open another terminal and start gdb-for-arm
$ ./gdb-for-arm
4. enter the following gdb commands to connect, reset, load and run uboot
(gdb) target remote localhost:3333
(gdb) mon reset
(gdb) load ./u-boot
# till here everything is fine, the prints shows various sections of u-boot to be loaded with .text being loaded at 0x17800000
# we also verified program counter to be set to 0x17800000
# after executing following command, we see no prints on uart , gdb and openocd
(gdb) cont
Can anyone please tell me what wrong are we doing?
Thanks and Regards,
Anand Mistry
Original Attachment has been moved to: bd_n6max.cfg.zip
Hi Anand
please check
imx6, arm, and linux - tips and tricks: Inexpensive JTAG on the imx6 solo: U-Boot Launch and Debug
https://boundarydevices.com/jtag-adaptor-for-i-mx6-boards/
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi, I'm trying to do the same, but for an iMX6q. Although I can see the BlogSpot.ru website page, there is no technical content behind it. Is it still available? Everything I've seen suggests that u-boot is loaded to DDR3, but this would not have been enabled until u-boot has run...
I can use OpenOCD to load_image to wherever needed. I can enable the on-board DDR3.
The SB-loader works fine for my development board, but USB is not intended to be provided for the production boards.
Thanks
just as example for running application with jtag (provided for ddr test) one can look on
i.MX6/7 DDR Stress Test Tool V3.00
Best regards
igor
Thanks for that suggestion. It works, but only if u-boot has already been loaded!
I've tried loading all the IO Mux configuration, the Enable DDR3 settings and the enable UART2 commands, but then if I load and run the stress tool: nothing. If I HALT the processor (under control of OpenOCD), the Program Counter shows a value in the Boot ROM, as opposed to one in the OCRAM when running OK on top of u-boot.
So I have to assume that there's something missing in the configuration, causing the processor to error and revert to its boot handler, even though the two setups are started in the same way (resume 0x00907174).
If I load u-boot, HALT it, then over-write all the IO Mux registers, then RESUME, u-boot still runs so I can't envisage IO Mux errors.
Any help would be appreciated.
Thanks, Nick
Hi Nick,
Are you still seeing the same issue? If not, could you please share your solution?
I am seeing exactly the same behaviour with another iMX6Q board, jumping into the boot ROM when I try to run the memory test via JTAG but all working fine when I run it via U-Boot. It appears as if U-Boot is configuring something that is missed in my JTAG init scripts, despite both of them using the same DCD tables.
Regards,
Sean
I seem to have found the root cause - the load operation was switching the CPU core state to Thumb. If I switch back to ARM mode ("imx6q.cpu.0 arm core_state arm" - I'm using OpenOCD) before continuing from GDB then all is well.
Regards,
Sean
Hi Nick
one can check if jtag performed all dcd settings as in uboot/board/freescale/mx6sabresd/mx6q_4x_mt41j128.cfg
Best regards
igor