aboutsummaryrefslogtreecommitdiff
path: root/src/jtag
AgeCommit message (Collapse)AuthorFilesLines
2015-08-06bcm2835gpio: Add SWD support, Raspberry Pi 2 support.Christoph Pittracher1-9/+158
Added support for SWD transport similar to sysfsgpio driver. Added configurable peripheral base address to support Raspberry Pi 2. Change-Id: If76d45fbe74ce49f1f22af72e5f246e973237e04 Signed-off-by: Christoph Pittracher <pitt@segfault.info> Reviewed-on: http://openocd.zylin.com/2802 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-08-06jlink: Add on-board nRF51-DK USB VID and PIDKyle Manna1-2/+2
* Add USB VID and PID for the J-Link interface running on the Nordic Semiconductor nRF51-DK. Also tested with debug out port to debug external boards. * Elimiantes need for `-c "jlink pid 0x1015"` on the openocd cmd line. Change-Id: Ib23acb72b9f5183b76fc7dc22b556982869ae830 Signed-off-by: Kyle Manna <kyle@kylemanna.com> Reviewed-on: http://openocd.zylin.com/2775 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-05-17jtag/drivers/stlink: fix SRST issue with stlink-v1Paul Fertser1-1/+1
Even though the latest firmware version for stlink-v1 supports "v2" JTAG API, the hardware SRST handling is still broken; amend the check accordingly. Change-Id: I62c662cd7aa209d2d6e9fe260f5c0be81d0ce672 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2761 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-04-24jtag/drivers/ti_icdi: do not segfault when adapter can't be openedPaul Fertser1-0/+3
Change-Id: Id3af8dfd18b13947bca4f3c89c2516ccbcef60b6 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2742 Tested-by: jenkins
2015-04-16configure the SWD frequency when setting adapter speed in SWD mode for versaloonSimon Qian1-1/+3
Change-Id: I99cdc11ba1442e4c9efaa0f1de8e7089ec725e14 Signed-off-by: Simon Qian <openocd@versaloon.com> Reviewed-on: http://openocd.zylin.com/2608 Tested-by: jenkins Reviewed-by: Tomas Vanek <vanekt@fbl.cz> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-04-16stlink_usb.c: Decode some more errors.Uwe Bonnes1-0/+8
Change-Id: I637cb63bd39120554aa184eaa48fd00a4852359f Signed-off-by: Uwe Bonnes <bon@elektron.ikp.physik.tu-darmstadt.de> Reviewed-on: http://openocd.zylin.com/2706 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-04-16cmsis-dap: print vendor and product id on open failureSpencer Oliver1-1/+1
Change-Id: Iae7ed8d59a722b805536550a8033f5fb7c85c5fc Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/2708 Tested-by: jenkins Reviewed-by: Andrey Yurovsky <yurovsky@gmail.com>
2015-04-14jtag/startup.tcl: fix regression with autoselecting JTAGPaul Fertser1-3/+2
This regression was introduced with d90b86d8. "transport select" doesn't throw an error anymore and autoselects the first available transport on its own. Reported by moyix on IRC. Change-Id: I3f303c0372e915931cca4b28af450694abc1a63e Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2693 Tested-by: jenkins
2015-04-14jtag/tcl: fix incorrect memcpy in jim_newtap_expected_idPaul Fertser1-10/+5
Found by clang static checker. On the very first call of jim_newtap_expected_id() pTap->expected_ids and expected_len are null, and there's nothing to copy. This patch changes this cryptic code to use realloc() instead. Change-Id: Ic0b5140d08257a906f15b55a2ae64db7bc06d5f1 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2562 Reviewed-by: Stian Skjelstad <stian@nixia.no> Tested-by: jenkins
2015-04-14startup: Fixed measure_clk to return kHz instead of MHz.Ed Beroset1-2/+3
The original code had iterated 10,000,000 times and taken the elapsed time divided by 10,000, to yield kHz which is mathematically correct only if we were measuring time in seconds, but we are measuring time in milliseconds, so the correct divisor is actually 10,000,000. Previous code would report 0.500 for actual measured speed of 500 kHz. Change-Id: Iba4c4961fe3973e7ccfa6dfa11d606a966ceb50c Signed-off-by: Ed Beroset <beroset@ieee.org> Reviewed-on: http://openocd.zylin.com/2573 Tested-by: jenkins Reviewed-by: Jens Bauer <jens@gpio.dk> Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2015-04-14jtag/core: honour SRST timings in SWD modePaul Fertser1-0/+6
Since SWD is currently abusing the JTAG command queue for reset and sleep handling (and all other operations are performed in a different way), sleep needs to be forced explicitly to ensure correct timings. Change-Id: I5b0da6cbb7d0560154e4077b261aa6828cefc892 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2591 Tested-by: jenkins Reviewed-by: Tomas Vanek <vanekt@fbl.cz> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-03-25jtag/drivers/ftdi.c: removed memory leakMateusz Manowiecki1-0/+2
swd_cmd_queue buffer memory leak removed Change-Id: Iafcdf034d32a37d577b58b6256c8fd9b064ce228 Signed-off-by: Mateusz Manowiecki <segmentation@fault.pl> Reviewed-on: http://openocd.zylin.com/2563 Tested-by: jenkins Reviewed-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-03-25drivers/cmsis-dap: port to common SWD frameworkPaul Fertser4-189/+207
Valgrind-tested. Comparison of flashing performance on an FRDM-KL25Z board running mbed CMSIS-DAP variant, 5MHz clock, old driver: wrote 28096 bytes from file demo.elf in 26.833590s (1.023 KiB/s) verified 27264 bytes in 1.754972s (15.171 KiB/s) this implementation: wrote 28096 bytes from file demo.elf in 3.691939s (7.432 KiB/s) verified 27264 bytes in 0.598987s (44.450 KiB/s) Also tested "Keil ULINK-ME CMSIS-DAP" with an STM32F100 target, 5MHz clock, results reading from flash, old driver: dumped 131072 bytes in 98.445305s (1.300 KiB/s) this implementation: dumped 131072 bytes in 8.242686s (15.529 KiB/s) Change-Id: Ic64d3124b1d6cd9dd1016445bb627c71e189ae95 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2356 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-03-25armv7m_trace, stlink: provide APIs to capture trace with an adapterPaul Fertser6-192/+183
Change-Id: I9d193dd5af382912e4fe838bd4f612cffd11b295 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2540 Tested-by: jenkins
2015-03-25armv7m: add generic trace support (TPIU, ITM, etc.)Paul Fertser1-4/+4
This provides support for various trace-related subsystems in a generic and expandable way. Change-Id: I3a27fa7b8cfb111753088bb8c3d760dd12d1395f Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2538 Tested-by: jenkins
2015-03-09jlink: Add variant "J-Link Lite-XMC4000"Andreas Färber1-0/+4
Avoids "J-Link hw type unknown 0x10" on the Infineon Relax Lite Kit. Change-Id: I3091623ead2e84b67ac20d9866307ccbb3f26f66 Signed-off-by: Andreas Färber <afaerber@suse.de> Reviewed-on: http://openocd.zylin.com/2568 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-03-09jlink: Add variant "J-Link Lite-XMC4200"Andreas Färber1-0/+4
Avoids "J-Link hw type unknown 0x11" on various Infineon boards. Change-Id: If20b9e21110d2acc02be57f5faf28c5e6a39e2c9 Signed-off-by: Andreas Färber <afaerber@suse.de> Reviewed-on: http://openocd.zylin.com/2565 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-03-09hla/hla_interface: call HLA layout API close() on quitPaul Fertser1-0/+3
This bug was exposed by Valgrind. Change-Id: I2e2bc036b49ca3ff22f78f765ee4537763350096 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2543 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-03-09stlink: avoid null pointer dereference in stlink_usb_close()Paul Fertser1-4/+4
Otherwise it happens if stlink can not be opened on start. Change-Id: I7088f10e61508dae230eccfe576a51498c92f5b8 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2550 Tested-by: jenkins Reviewed-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-by: Stian Skjelstad <stian@nixia.no>
2015-03-09jtag/drivers/buspirate: add JTAG_STABLECLOCKS cmdMateusz Manowiecki1-0/+15
Solution found on the internet Change-Id: Ied6f7d9b28131a7ac83b203e4c64d4e9ffec0595 Signed-off-by: Mateusz Manowiecki <segmentation@fault.pl> Reviewed-on: http://openocd.zylin.com/2496 Tested-by: jenkins Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2015-02-22Add SWD protocol support to sysfsgpioJean-Christian de Rivaz1-49/+229
Based on the initial work on bcm2835gpio.c by Paul Fertser with many additions. Modifications to the GPIO handling was minimal in this patch. A more big modification is required before cleanup the interface between bitbang and sysfsgpio. Change-Id: I54bf2a2aa2ca059368b0e0e105dff6084b73d624 Signed-off-by: Jean-Christian de Rivaz <jc@eclis.ch> Reviewed-on: http://openocd.zylin.com/2438 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2015-02-22Add SWD protocol support to bitbangJean-Christian de Rivaz2-0/+222
This is based on the initial work by Paul Fertser with addition of the switch sequences and new ACK handling. In case of WAIT response, the sticky bits are cleared and the last operation is repeated. The ACK handling is based on the interpretation of the 8 February 2006 ARM Debug Interface v5 Architecture Specification Change-Id: Id50855b1ffff310177ccf9883dc9eb0d1b4458c8 Signed-off-by: Jean-Christian de Rivaz <jc@eclis.ch> Reviewed-on: http://openocd.zylin.com/2437 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-by: Paul Fertser <fercerpav@gmail.com> Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2015-02-11J-Link serial number config optionJoerg Fischer1-2/+23
Add serial option to jlink config commands, handy when there is more than one adapter connected. To select adapter 0123456 for OpenOCD, use jlink serial 0123456 Change-Id: Ib29ce3f0c4975e1169211721a4531bf4db61f1ee Signed-off-by: Joerg Fischer <turboj@gmx.de> Reviewed-on: http://openocd.zylin.com/2521 Tested-by: jenkins Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2015-02-11jlink: Added hardware version number for JLink firmware on LPC-Link2Nemui Trinomius1-14/+25
JLink firmware on LPC-Link2 has unique hardware version number(0x12). Change-Id: I76b6e27c47d236da75c61dd6b83d6a823615968d Signed-off-by: Nemui Trinomius <nemuisan_kawausogasuki@live.jp> Reviewed-on: http://openocd.zylin.com/2298 Tested-by: jenkins Reviewed-by: Anders Oleson <anders@openpuma.org> Reviewed-by: Xiaofan <xiaofanc@gmail.com> Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2015-01-30drivers/stlink: clarify "init mode failed" messagePaul Fertser1-1/+1
The message as it was didn't let the user know that something was wrong with the target or wiring. Change-Id: Ib609c2d31959e77413e61c348d0e31d7269d5c58 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2365 Tested-by: jenkins Reviewed-by: Uwe Bonnes <bon@elektron.ikp.physik.tu-darmstadt.de> Reviewed-by: Jens Bauer <jens@gpio.dk>
2015-01-30jtag/drivers: remove useless checks causing build failure with clang 3.5.0Paul Fertser2-6/+0
Change-Id: Icafab6ac1e3e79c6da1bc163c30744eee4bde8d3 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2482 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-by: Andreas Färber <afaerber@suse.de>
2015-01-30Use (uint8_t *) for buf_(set|get)_u(32|64) instead of (void *)Paul Fertser1-1/+1
This helps to uncover incorrect usage when a pointer to uint32_t is passed to those functions which leads to subtle bugs on BE systems. The reason is that it's normally assumed that any uint32_t variable holds its value in host byte order, but using but_set_u32 on it silently does implicit pointer conversion to (void *) and the assumption ends up broken without any indication. Change-Id: I48ffd190583d8aa32ec1fef8f1cdc0b4184e4546 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2467 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2015-01-28jtag: Rewrite TAP verification/auto-probe logicAndreas Fritiofson1-106/+76
Enable auto-creating additional discovered TAPs even if some TAPs are predefined, avoiding initialization failure when it's not necessary. Also, drop the arbitrary limit on the number of predefined TAPs. Still, don't auto-create any if there are more than 20 TAPs already, to stop a noisy connection from creating unlimited TAPs. Create auto-probed TAPs with less noise. Reduce code duplication between verification and auto-probing. Change-Id: I82a504d92dbcc0060206e71f10c5158256b5f561 Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-on: http://openocd.zylin.com/2236 Tested-by: jenkins Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2015-01-26jtag/drivers/cmsis-dap-usb: fix cmsis_dap_serialJaakko Kukkohovi1-2/+8
Previously the serial wasn't actually used in hid_open() call, which meant that the first device with matching vid:pid was opened irrespective of the actual serial number. Change-Id: I45216ae5d9e0798e97be693c30e2f03c89b9a02b Signed-off-by: Jaakko Kukkohovi <jkukkohovi@gmail.com> Reviewed-on: http://openocd.zylin.com/2487 Tested-by: jenkins Reviewed-by: Jörg Wunsch <openocd@uriah.heep.sax.de> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-01-26jtag/drivers/stlink: demote the output of available speeds to DEBUGPaul Fertser1-2/+2
Change-Id: If0afb6fb1cb2f39619e4e614573065c145255c3e Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2469 Reviewed-by: Jens Bauer <jens@gpio.dk> Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-01-26jtag/hla_interface: avoid segfault with adapters that do not have ↵Paul Fertser1-0/+3
configurable speed Change-Id: I0386cbfc85ba8b28d3819530f9950b31545d6821 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2468 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-01-15stlink: add reconfigurable speed supportSpencer Oliver1-0/+108
The ability to change the speed has been added to firmware versions J22 and above. Any attempt to change on earlier versions will be ignored without error, as the existing code does. For supported firmware versions the driver will attempt to get as close as possible to supported speeds (never higher). The default stlink speed on power up is 1.8MHz. The driver will now also print supported clocl speeds during init. Change-Id: Iee9bd018bb8b6f94672a12538912d41c23d48a7e Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/2335 Tested-by: jenkins
2015-01-15hla: add ability to change adapter speed (if supported)Spencer Oliver3-8/+23
As a note we need to cache the requested speed setting, as the hla interface may not be ready when the first adapter_khz is called. Change-Id: I2fa6807d5f0bd3f0365cf178bd10a230c39415a7 Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/2334 Tested-by: jenkins
2015-01-15jtag/hla: output possible idcode candidates in case of mismatchPaul Fertser1-2/+5
Output a similar message to what we have on low-level JTAG adapters to avoid confusing users. Reported on IRC by chickensk. Change-Id: I96d58410ef715b966e32d79c0aacf38596c5eb3f Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2451 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-01-15jtag: Avoid extra SRSTn resets when connectingEvan Hunter1-1/+2
Previously the jtag_add_reset(1, 0) caused the processor to be released, and if SRSTn existed then it would then be reset again two lines later. Change-Id: I58b7a12607f46f83caa7ed3b3cebc4195eb51ef6 Signed-off-by: Evan Hunter <ehunter@broadcom.com> Reviewed-on: http://openocd.zylin.com/2398 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-01-09swd: handle various failure conditionsPaul Fertser2-14/+3
When communication with target fails for whatever reason, it makes sense to do JTAG-to-SWD (in case the target got power-cycled or the DAP method was reset anyhow), SWD line reset sequence (part of JTAG-to-SWD already) and the mandatory IDCODE read. Schedule that to be performed on the next poll. Fix the return values for ftdi and jlink drivers to be consistent with OpenOCD error codes and remove ad-hoc calls to perform DAP method switching (as it's now done from the upper layer automatically). Change-Id: Ie18797d4ce7ac43d8249f8f81f1064a2424e02be Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2371 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-by: Mateusz Manowiecki <segmentation@fault.pl>
2015-01-07jtag: Remove unnecessary global variableAndreas Fritiofson1-8/+12
Change-Id: I96e5f13b12da2970eafc5fca24b7952d427eeca9 Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-on: http://openocd.zylin.com/2235 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2015-01-07jtag: Fix memory leaks in jtag_tap_free()Andreas Fritiofson1-1/+2
Change-Id: I953fbb346fbf168fb50b349d245f2aa64dbfdcb3 Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-on: http://openocd.zylin.com/2234 Tested-by: jenkins
2014-11-24jtag/drivers/jlink: implement register command to fix SWDPaul Fertser1-0/+44
Some J-Link fw versions require registration to be performed before SWD operation is possible. It doesn't harm anyway, vendor's utilities do it unconditionally. Thanks go to Segger for providing the necessary information. Change-Id: Iabd76c743eca86e2c817a97cb93c969fec3f7ac6 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2331 Tested-by: jenkins
2014-10-16cmsis-dap: add serial number supportSpencer Oliver1-1/+40
Change-Id: I66926d1013e2b3a43ce0d18d3599771428706b6a Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/2329 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2014-10-16cmsis-dap: refactor HID PID/VID check loopSpencer Oliver1-15/+21
In preparation for adding serial number support. Change-Id: I3c9fb411b79d54a4d2de067039255436ba6708c7 Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/2328 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2014-10-06libusb: introduce jtag_libusb_choose_interface() and use it for JLinkPaul Fertser6-49/+79
This introduces a new common function that allows auto-discovery of a suitable USB interface based on class, subclass and protocol matching. It claims the interface and returns the corresponding endpoints number to the caller. The need for this arised due to nRF51822 USB dongle which comes with an "on-board Segger J-link debugger" having 3 interfaces, so the current code can't work at all with it (in this particular case the last interface needs to be choosen). This also removes special handling of JLink-OB endpoint numbers as it's now possible to autodetect them as well as the standard JLink endpoints. Change-Id: I4d990a7a3b373efdd2949a394b32d855a168e138 Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2327 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-10-06hla: add a way to pass arbitrary commands from user to layout and use for ICDIPaul Fertser3-0/+25
TI's ICDI adapter supports some additional commands which a user might want to run for debugging or other purposes, the most useful of them being "debug unlock" that fully mass-erases the device and unprotects the flash. Change-Id: I26990e736094367f92106fa891e9bb8fb0382efb Signed-off-by: Paul Fertser <fercerpav@gmail.com> Reviewed-on: http://openocd.zylin.com/2263 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-10-06jtag/drivers/jlink.c: fix for LPC Link-2 running JLink firmware on LinuxAnders1-10/+12
Change 2288 fixed the extraneous reset caused by set_configuration that crashed the LPC Link-2 running JLink firmware and works on windows platforms. On Linux however, conditional code was still calling USB reset and caused the adapter to crash on any non-windows platforms. Change-Id: Ibf2a02d0dcdd91ccb71d86231cd8311dcadfee1e Signed-off-by: anders@openpuma.org Reviewed-on: http://openocd.zylin.com/2297 Tested-by: jenkins Reviewed-by: Xiaofan <xiaofanc@gmail.com> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-10-06jtag/drivers/libusb1_common: avoid device reset when reselecting configurationAnders1-2/+14
According to [1], we shouldn't reselect an already active configuration to avoid needless device reset. This is known to cause issues with e.g. LPC Link2 with JLink firmware. [1] http://libusb.sourceforge.net/api-1.0/caveats.html#configsel Change-Id: I3568ada77780a521548c450090db7173f8d0b2dd Signed-off-by: Paul Fertser <fercerpav@gmail.com> Signed-off-by: Anders Oleson <anders@openpuma.org> Reviewed-on: http://openocd.zylin.com/2288 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-10-06jtag: constify driver arraysSpencer Oliver11-24/+24
Change-Id: I81574fa8ca3cc748526dc61b75a2c75d6335ef04 Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/2294 Tested-by: jenkins
2014-09-29vsllink: improve the performance when using swdSimon Qian1-50/+4
Versaloon firmware has been updated for reporting errors if fail on swd transactions. Change-Id: I49ac0ad034cc9ad83cc4e43953579811d1243063 Signed-off-by: Simon Qian <openocd@versaloon.com> Reviewed-on: http://openocd.zylin.com/2302 Reviewed-by: Fatih Aşıcı <fatih.asici@gmail.com> Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-09-22mpsse: Display libusb error names instead of numbersJoakim Gebart1-15/+15
Added calls to libusb_error_name() where applicable in order to easier understand the error messages. Change-Id: I3fe3d4b5624ae0de37c36e54a371eba5535ccaa1 Signed-off-by: Joakim Gebart <joakim.gebart@eistec.se> Reviewed-on: http://openocd.zylin.com/2289 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-09-22Support hla_serial command for ST-LINK adapters.Austin Phillips10-31/+120
The hla_serial command allows for a programming device serial number to be specified in addition to USB VID/PID. This allows for multiple ST-LINK/V2 programmers to be attached to a single machine and operated using openocd. Change-Id: I350654bf676eb26ba3a90450acfa55d2a5d2d791 Signed-off-by: Austin Phillips <austin_phillips@hotmail.com> Reviewed-on: http://openocd.zylin.com/2198 Tested-by: jenkins Reviewed-by: Martin Glunz <mg@wunderkis.de> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-09-15jtag: drivers: stlink: remove unnecessary '\n' in LOG_* entriesAndrey Skvortsov1-5/+5
Change-Id: Ia2dc3efc27b53334af4d85f9807abba0463c291b Signed-off-by: Andrey Skvortsov <andrej.skvortzov@gmail.com> Reviewed-on: http://openocd.zylin.com/2220 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>