As mentioned before, in order to support SWD, the existing ARM ADIv5 code needs to get rid of its current dependency on JTAG as a debug transport ... and a good way to handle that is to just define an abstract DAP interface, for which we'll provide both JTAG and SWD implementations.
Here's a works-with-JTAG version of that. I'll hold off a few days before committing it, to collect comments, but I don't currently have any reservations about these patches. 1 Add a new new interface abstracting DAP operations, and implements the JTAG ops using existing code 2 Switch to one of the operations in the new interface, and make it so the JTAG implementation is no longer exposed 3 Similarly for the two DP operations (register read/write); this is internal to the ADIv5 code 4 And for the AP operations (register r/w) ... this is mostly but no completely internal to ADIv5 Not included here is a patch to move all the JTAG-specific logic into a new ADIv5 file, so it's only accessible through the new interface calls. The reason is described in a FIXME in the patch for AP operations, and a note in the patch comments. Briefly, one block I/O routine needs updates that are a bit more than the "make a different call" syntax-ish changes above. - Dave p.s. Sanity tested on Cortex-M3, but not yet Cortex-A8. _______________________________________________ Openocd-development mailing list [email protected] https://lists.berlios.de/mailman/listinfo/openocd-development
