Tim Newsome
27b94d36d0
Fix 32-bit build.
2016-09-23 14:16:23 -07:00
Tim Newsome
668070cc45
Faster download.
...
16K testcase:
Transfer rate: 53 KB/sec, 2222 bytes/write.
2016-09-23 14:16:23 -07:00
Tim Newsome
9aab0aa068
Minor cleanup.
2016-09-23 14:16:23 -07:00
Tim Newsome
06f6b5020c
Use optimized cache/program write scheme for most
...
operations.
2016-09-23 14:16:23 -07:00
Tim Newsome
a1875fbecf
Working on optimized program running.
...
Makes a big difference on the XLEN code (29ms to 8ms). Now to use it in
more places.
2016-09-23 14:16:23 -07:00
Tim Newsome
9b9653ab7d
Use hardware single step.
2016-09-23 14:16:23 -07:00
Tim Newsome
eac8933b89
WIP on performance improvement.
...
Also implement empty arch_state to prevent occasional startup crash.
2016-09-23 14:16:23 -07:00
Tim Newsome
2d02e77bed
Make this compile for 32-bit targets.
2016-09-23 14:16:23 -07:00
Tim Newsome
aaa8ce10b8
Correctly figure out the number of extant hwbps.
2016-09-23 14:16:23 -07:00
Tim Newsome
c471cfb63b
Simple execute hardware breakpoint works.
2016-09-23 14:16:23 -07:00
Tim Newsome
cb57aa55fa
Deal with exceptions on register read.
...
Cache dpc, so we can restore it when it's clobbered by an exception.
2016-09-23 14:16:23 -07:00
Tim Newsome
b81a846be5
Cache dcsr, since we're reading it anyway.
2016-09-23 14:16:23 -07:00
Tim Newsome
c8430bb8f4
DebugTest.test_interrupt passes now.
2016-09-23 14:16:23 -07:00
Tim Newsome
e10d407623
Speed up memory read a little.
2016-09-23 14:16:23 -07:00
Tim Newsome
4b19b7305f
Save/restore T0 around block writes.
2016-09-23 14:16:23 -07:00
Tim Newsome
90f458e63f
Reading/writing s1 now works.
2016-09-23 14:16:23 -07:00
Tim Newsome
0881092d9b
Can successfully run to a swbp.
2016-09-23 14:16:23 -07:00
Tim Newsome
c364bd0ab5
We can run to a software breakpoint, but
...
gdb doesn't notice we're halted once we hit it, even though riscv_poll()
is setting the target state to halted.
2016-09-23 14:16:23 -07:00
Tim Newsome
04cfc35147
Use the dram cache to save some scans.
2016-09-23 14:16:23 -07:00
Tim Newsome
dce4a992a3
Single memory reads/writes work.
2016-09-23 14:16:23 -07:00
Tim Newsome
39788e5e6b
Fix typo in comment.
2016-09-23 14:16:23 -07:00
Tim Newsome
1b349df638
WIP hackery.
...
Main thing I added is code to output "verilog" for every JTAG op we do,
so we can run the same thing in simulation.
2016-09-23 14:16:23 -07:00
Tim Newsome
f40862d87c
Go through run-test/idle once per dbus access.
2016-09-23 14:16:23 -07:00
Tim Newsome
9f22176618
Reading registers appears to work.
2016-09-23 14:16:23 -07:00
Tim Newsome
84944ded87
Fix up some register stuff.
...
Now you can attach with gdb, and it'll attempt to read a register. That
will fail because the core won't clear debug interrupt. Adding nops
doesn't help this time.
2016-09-23 14:16:23 -07:00
Tim Newsome
f634702aaf
Successfully determine xlen.
...
There's a nop in there for no reason, though.
2016-09-23 14:16:23 -07:00
Tim Newsome
db06dd45a0
Improve error checking.
2016-09-23 14:16:23 -07:00
Tim Newsome
40e42c5a04
Print out really long scan values.
2016-09-23 14:16:22 -07:00
Tim Newsome
63f6999b6d
Print idcode value in error message.
2016-09-23 14:16:22 -07:00
Tim Newsome
041e0ccf9e
Selecting dbus is sometimes necessary.
2016-09-23 14:16:22 -07:00
Tim Newsome
25e8b66b08
WIP registers.
2016-09-23 14:16:22 -07:00
Tim Newsome
ae74097f39
Add extra debug output.
...
This probably shouldn't be in the final change list.
2016-09-23 14:16:22 -07:00
Tim Newsome
3b60c3aa42
Fix bug when waiting for debugint to clear.
2016-09-23 14:16:22 -07:00
Tim Newsome
67009979ae
Clearer debug logging.
2016-09-23 14:16:22 -07:00
Tim Newsome
3b3beb04ef
WIP on registers.
2016-09-23 14:16:22 -07:00
Tim Newsome
330ff8b2c9
Try to document struct reg.
2016-09-23 14:16:22 -07:00
Tim Newsome
482497c51a
Blind implementation of write_memory.
2016-09-23 14:16:22 -07:00
Tim Newsome
50ca8ac373
Blind implementation of read_memory.
2016-09-23 14:16:22 -07:00
Tim Newsome
76fe7db0db
In theory assert_reset/deassert_reset work.
2016-09-23 14:16:22 -07:00
Tim Newsome
ea6836c5f6
WIP, blind coding.
2016-09-23 14:16:22 -07:00
Tim Newsome
413ab49dfd
Blind coding new dbus behavior.
2016-09-23 14:16:22 -07:00
Tim Newsome
feff2dd9e7
Always leave the TAP in Run-Test/Idle.
2016-09-23 14:16:22 -07:00
Tim Newsome
98f2fa897f
Halt should work now.
2016-09-23 14:16:22 -07:00
Tim Newsome
bb0463deec
Set up dram structure; implement poll().
2016-09-23 14:16:22 -07:00
Tim Newsome
495384e15f
Figure out Debug RAM size in examine().
...
It compiles, so that means it works, right?
2016-09-23 14:16:22 -07:00
Tim Newsome
48cf8eebf1
Scaffolding.
2016-09-23 14:16:22 -07:00
Tim Newsome
10bcfdad71
Refer to nonexistent riscv target.
2016-09-23 14:16:22 -07:00
Andreas Färber
81631e49a6
contrib/loaders: Enforce Little Endian ARM machine code
...
arm-none-eabi target triplet defaults to Little Endian, and so far any
submitted machine code snippets have been verified to be Little Endian.
However a user might override [ARM_]CROSS_COMPILE with an armeb toolchain,
potentially resulting in invalid machine code.
Let's be safe and enforce Little Endian mode for assembler and compiler.
Change-Id: I9cefe24689eaded25d60ffb1f254b254e8d76f9d
Signed-off-by: Andreas Färber <afaerber@suse.de>
Reviewed-on: http://openocd.zylin.com/3498
Tested-by: jenkins
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2016-08-14 11:45:15 +01:00
Tomas Vanek
0e95629eb1
flash Kinetis: Implement flash protection setting
...
Kinetis family employs strange concept of Flash Configuration Field at
address 0x400 of program flash. Writing incorrect data to FCF may
permanently lock the device.
The change introduces 'kinetis fcf_source protection' mode. In this mode
write of flash image data to FCF is prevented. FCF data build from
protection (set by 'flash protect' command) are written instead.
FCF data are written also just after erase of relevant sector. It
protects device from locking security by reset or power cycle after erase.
prot_blocks array is used as protection blocks have bigger size than sectors.
Alignment and padding programming sections is rewritten to fix
writing with not section boundary aligned begin.
Change-Id: I9fc8bd37d6f627fb8ed7abb7f7560e78a740b195
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: http://openocd.zylin.com/3562
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Tested-by: jenkins
2016-08-14 11:41:09 +01:00
SASANO Takayoshi
d856aa9771
pic32mx: add new device ID, 17x/27x Flash support
...
- add new device ID: 170F256B, 170F256D, 270F256B, 270F256D,
330F064H, 330F064L, 430F064H, 430F064L, 350F128H, 350F128L,
450F128H, 450F128L, 350F256H, 350F256L, 450F256H, 450F256L,
370F512H, 370F512L, 470F512H, 470F512L
- add support for PIC32MX17x/27x 256kB Flash
Change-Id: I65a304d2114fff80de3a24c1f6d0b5e955b22531
Signed-off-by: SASANO Takayoshi <uaa@uaa.org.uk>
Reviewed-on: http://openocd.zylin.com/3186
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2016-08-14 09:34:10 +01:00