|
From: Brendan Dolan-G. <bre...@ga...> - 2014-02-12 04:02:32
|
After updating to the latest git master, I noticed that OpenOCD now comes with a Linksys WRT54GL config by default. With that I have managed to get some slightly different output, including something that resembles the correct PC and register contents. But the target still does not actually halt, and instead reboots itself. $ telnet localhost 4444 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. Open On-Chip Debugger > halt Error writing unexpected address 0xff202004 DMA time out DMA Read Addr = 0ff30008 Data = ERROR ON READ target state: halted target halted in MIPS32 mode due to debug-request, pc: 0x80003054 > reg ===== mips32 registers (0) zero (/32): 0x00000000 (1) at (/32): 0x00000000 (2) v0 (/32): 0x00000000 (3) v1 (/32): 0x8018F34C (4) a0 (/32): 0x00000019 (5) a1 (/32): 0x00000000 (6) a2 (/32): 0x1000FC01 (7) a3 (/32): 0xFFFF00FF (8) t0 (/32): 0x8015FFE0 (9) t1 (/32): 0x0000FC00 (10) t2 (/32): 0x00000000 (11) t3 (/32): 0x80E0B41C (12) t4 (/32): 0x00000030 (13) t5 (/32): 0x00000006 (14) t6 (/32): 0x19999999 (15) t7 (/32): 0x00000000 (16) s0 (/32): 0x80341E70 (17) s1 (/32): 0x00000000 (18) s2 (/32): 0x803029FC (19) s3 (/32): 0x43464531 (20) s4 (/32): 0x00000002 (21) s5 (/32): 0x00000400 (22) s6 (/32): 0x00000001 (23) s7 (/32): 0x00000400 (24) t8 (/32): 0x00000000 (25) t9 (/32): 0x2AC716E0 (26) k0 (/32): 0x8015FF58 (27) k1 (/32): 0x8015FF58 (28) gp (/32): 0x8015E000 (29) sp (/32): 0x8015FF58 (30) fp (/32): 0x00000000 (31) ra (/32): 0x80003070 (32) status (/32): 0x1000FC01 (33) lo (/32): 0x00000BC0 (34) hi (/32): 0x00000000 (35) badvaddr (/32): 0xC0074298 (36) cause (/32): 0x00008400 (37) pc (/32): 0x80003054 > reset halt JTAG tap: bcm5352e.cpu tap/device found: 0x0535217f (mfg: 0x0bf, part: 0x5352, ver: 0x0) timed out while waiting for target halted TARGET: bcm5352e.cpu - Not halted in procedure 'reset' Halt timed out, wake up GDB. > I have also attached a log generated with the "-d" option. Thanks, Brendan On Tue, Feb 11, 2014 at 8:44 PM, Brendan Dolan-Gavitt <bre...@ga...> wrote: > Hi, > > I'm trying to use OpenOCD to talk to a Linksys WRT54GL via a > Flyswatter2. OpenOCD correctly reads the JTAG ID of the device > (0x0535217f), but I can't seem to get it to halt the target. Just > issuing "halt" causes the device to reboot. A "reset halt" doesn't > reboot the device, but it times out. Here's the OpenOCD output when > starting it with "sudo src/openocd -s tcl -f interface/flyswatter2.cfg > -f target/bcm5352e.cfg": > > === BEGIN OPENOCD OUTPUT === > $ telnet localhost 4444 > Trying 127.0.0.1... > Connected to localhost. > Escape character is '^]'. > Open On-Chip Debugger >> halt > target state: halted > target halted in MIPS32 mode due to debug-request, pc: 0x00000000 >> targets > TargetName Type Endian TapName State > -- ------------------ ---------- ------ ------------------ ------------ > 0* bcm5352e.cpu mips_m4k little bcm5352e.cpu running >> reset halt > JTAG tap: bcm5352e.cpu tap/device found: 0x0535217f (mfg: 0x0bf, part: > 0x5352, ver: 0x0) > Halt timed out, wake up GDB. > timed out while waiting for target halted > TARGET: bcm5352e.cpu - Not halted > > in procedure 'reset' >> > === END OPENOCD OUTPUT === > > Any ideas? My config files are pasted below. > > Thanks, > Brendan > > === BEGIN flyswatter2.cfg === > # > # TinCanTools Flyswatter 2 > # > # http://www.tincantools.com/product.php?productid=16153 > # > > interface ft2232 > ft2232_device_desc "Flyswatter2" > ft2232_layout "flyswatter2" > ft2232_vid_pid 0x0403 0x6010 > adapter_khz 6000 > === END flyswatter2.cfg === > > === BEGIN bcm5352e.cfg === > set _CHIPNAME bcm5352e > set _CPUID 0x0535217f > > jtag newtap $_CHIPNAME cpu -irlen 8 -ircapture 0x1 -irmask 0x1f > -expected-id $_CPUID > > set _TARGETNAME $_CHIPNAME.cpu > target create $_TARGETNAME mips_m4k -endian little -chain-position $_TARGETNAME > == END bcm5352e.cfg === |