On 16/08/13 23:16, Greg Ungerer wrote:
> On 16/08/13 22:48, Philip Craig wrote:
>> On Fri, Aug 16, 2013 at 10:40 PM, Greg Ungerer <[email protected]> wrote:
>>> Has anyone used openocd on the Marvell ARAMADA 370 SoC?
>>>
>>> I have a Globalscale Mirabox and am trying to get JTAG debugging working
>>> on it. I am using an Amontec jtagkey, and have some basic functionality
>>> working. But I can't access the bus in any way without getting errors
>>> like this:
>>>
>>>       > arm disassemble 0x0063C9A0 10
>>>       JTAG-DP STICKY ERROR
>>>       MEM_AP_CSW 0x28000d2, MEM_AP_TAR 0x63c9a0
>>>       JTAG-DP STICKY ERROR
>>>       MEM_AP_CSW 0x28000d2, MEM_AP_TAR 0x63c9a0
>>>       Block read error address 0x63c9a0
>>>       in procedure 'arm'
>>>
>>> I can halt the cpu, single step, set breakpoints and run to it.
>>> I can dump the registers and get (what looks like) good values.
>>> But just can't access anything on the bus.
>>
>> That sounds similar to a problem I was having with imx6. Try 'dap apcsw 1'.
> 
> Thanks. Quick test seems to show it still produces the same error.
> If I do "dap apcsw" I get back:
> 
>    apsel 0 selected, csw 0x40000000
> 
> And I get the same result after running "dap apcsw 1". Not sure if
> that is right.

What I needed was:

    dap apsel 1

After that I can sometimes disassemble at the stopped pc :-)

When the unit is running linux (so MMU enabled) I can dissemble.
But say when running uboot then it fails with:

  > halt
  target state: halted
  target halted in ARM state due to debug-request, current mode: Supervisor
  cpsr: 0x800001d3 pc: 0x00647ae0
  MMU: disabled, D-Cache: disabled, I-Cache: enabled
  > arm disassemble 0x00647ae0 5
  647ae0 access in userspace and target in supervisor
  in procedure 'arm'
  > mdw 0x00647ae0 16
  647ae0 access in userspace and target in supervisor
  in procedure 'mdw'

Trying to access other memory regions results in errors like:

  > mdw 0xd0012000 16           
  trying to enable mmu on target stopped with mmu disable
  in procedure 'mdw'

Why is it trying to enable the MMU to do this?

Regards
Greg



------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead. 
Download for free and get started troubleshooting in minutes. 
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to