|ARM Technical Support Knowledge Articles|
The i.MX processor family from Freescale implements various power saving features. Two features need careful consideration when performing JTAG debug:
Clock gating of the debug logic
When this feature is enabled it is impossible for any debugger to connect and debug the processor through the JTAG interface. The clocks driving the debug logic are stopped to save power.
Sleep state through the Wait-For-Interrupt (WFI) instruction
When the processor is not in use or is waiting for system resources to become available, the OS may execute a WFI instruction to put the processor in sleep mode. This behaviour can interfere with a debug session and prevent breakpoints from getting hit.
These power saving features are disabled/unused after reset, and typically only enabled/used once the OS boots up.
The power saving features above have been seen with both Linux and WinCE OSs. In order to check this, please try halting the target in the bootloader (i.e. before the OS has been booted but after the external memory has been initialised) and then try connecting to the target using DS-5 or RVD.
If you are able to connect at this point, then clearly debugger communication to the target is proven, but that the target is subsequently affecting JTAG communications once the OS has booted.
If using Linux with the i.MX BSP from Freescale, you can add the following Linux kernel boot argument to disable debug clock gating and WFI usage:
Please note that advice on OS BSPs is outside the scope of this article. Please contact Freescale for further information on how to configure any of their supplied BSPs.
If a debug connection can be made at the bootloader prompt but not afterwards, even once 'jtag=on' has been specified as a kernel boot argument then you need to contact the supplier of the BSP.
Article last edited on: 2014-04-30 10:40:54
Did you find this article helpful? Yes No
How can we improve this article?