Commit Graph

5974 Commits

Author SHA1 Message Date
Spencer Oliver 00d6925b41 doxygen: use inline jtag state maching image
The currently used image is 404 so use an inline image instead.

Change-Id: I56a0d187fd06dc2c5c370e6532d89815ccec63d6
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1451
Tested-by: jenkins
2013-07-01 08:50:31 +00:00
Robert Jarzmik 9188a9bc68 target: xscale make reset init work properly
On XScale architecture, to write debug control register DCSR
and activate JTAG debug (ie. to choose Halt Mode), the
enabling can only be done while the board is held in reset
state (ie. PXAxx #RST line held low).

The current implementation writes to the register before
asserting the SRST line. Swap the order to activate the SRST
line before writing to DCSR.

Change-Id: I914b9d53d39bdeb5fe4ee5e11068cafafe0da4d2
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Reviewed-on: http://openocd.zylin.com/1458
Tested-by: jenkins
Reviewed-by: Marek Vasut <marek.vasut@gmail.com>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:49:11 +00:00
Robert Jarzmik 12e25f34eb target: xscale more human vector catching
Replace hexadecimal masks for vector catching with words
representing the caught exception, such as dabt for data
abort, etc ...
This way, the new xscale command is :
 - xscale vector_catch
   Reads back to the user the current vector catching status
 - xscale vector_catch reset dabt pabt
   Sets the caught vectors to data abort and prefetch abort
   for example.

This is mostly taken from Cortex-M3 openocd code.

Change-Id: I66591d5796f0e07f0f31edc8d28722e1e48aa8c5
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Reviewed-on: http://openocd.zylin.com/1456
Tested-by: jenkins
Reviewed-by: Marek Vasut <marek.vasut@gmail.com>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:44:59 +00:00
Ulf Wetzker ffcfbb0215 at91sam3: Added support for at91sam3s8a, b and c
Only the support for at91sam3s8b is tested on real hardware.

Change-Id: I4ce23bc2f6131d9cf3ff1b301ab9e470d20845ab
Signed-off-by: Ulf Wetzker <ulf.wetzker@eas.iis.fraunhofer.de>
Reviewed-on: http://openocd.zylin.com/1424
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:40:21 +00:00
Ulf Wetzker b3d4a44686 at91sam3: Added support for at91sam3sd8a and b
This update is untested due to missing hardware.

Change-Id: Ibe286b741ebbb1c8ae0bd3dea4b8f3e12320ab34
Signed-off-by: Ulf Wetzker <ulf.wetzker@eas.iis.fraunhofer.de>
Reviewed-on: http://openocd.zylin.com/1423
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:40:17 +00:00
Ulf Wetzker 8d70c86200 flash/nor/at91sam3: fixed lock region size
According to the "AT91SAM ARM-based Flash MCU SAM3S Series datasheet"
(http://www.atmel.com/Images/doc11090s.pdf) p. 30 the lock region
size for the at91sam3sd9 family is 32 kbyte.

This fix is only based on the datasheet due to missing hardware.

Change-Id: Ic47b0642e4f11a60de477eaa0167038103b8ff15
Signed-off-by: Ulf Wetzker <ulf.wetzker@eas.iis.fraunhofer.de>
Reviewed-on: http://openocd.zylin.com/1422
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:40:12 +00:00
IS2T 34e8d1a50d Support for SST 39VF3201C NOR flash
* Add Thumb-2 code to write flash memories that don't support DQ5 polling
 * Make sure default values for unlock commands are set even if there is no PRI information given by the flash
 * Add a fixup to disable DQ5 polling for the SST 39VF3201C

Change-Id: Ib08cf20547d0f500d5f78241521e6b49050c3d40
Signed-off-by: IS2T development team <dev.is2t@gmail.com>
Reviewed-on: http://openocd.zylin.com/1449
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:39:36 +00:00
Paul Fertser 434afb370f armv4_5: prevent segfault when gdb connects to an underinitialised target
This prevents segmentation fault that can occur on cortex_a targets if
gdb connection is established before it's halted and CPSR examined.

Change-Id: Id996200e0fd95440496509c1fecaabbdbf425e23
Tested-by: Henrik Nordstrom <hno@squid-cache.org>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1446
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:39:00 +00:00
Zied Guermazi a6863e9a52 keep gdb aware of threads if RTOS is set but no threads are created
if gdb server (openocd) answers qfThreadInfo with an empty string during boot,
gdb will not request thread info anymore. to keep thread awareness in gdb,
we have to answer with a non empty string, 'l' indicates an end of list,
and is a valid answer here.

Change-Id: I7870a5db1090c786f306db16a25871e69b8a9760
Signed-off-by: Zied Guermazi <guermazi.zied@gmail.com>
Reviewed-on: http://openocd.zylin.com/1432
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:38:32 +00:00
Spencer Oliver 146dfe3295 cortex_m: deprecate soft_reset_halt
soft_reset_halt was only really intended for the older arm arch, eg. armv4/5.
Newer arch such as armv7m/mips do not need this as they have better alternatives.

Change-Id: Ifb360680b7e4bfa5365f3c79d82574bded952b45
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1442
Tested-by: jenkins
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2013-07-01 08:37:44 +00:00
Andreas Fritiofson 3e90b63b1f Allow autoscan up to 64 bit IR lengths
Change-Id: Ib15ff67b57606fe6c7997f3f9bd90e096acd5f3d
Signed-off-by: Evan Hunter <ehunter@broadcom.com>
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/832
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:37:27 +00:00
Evan Hunter 7641fb6ac6 Add support for 64 bit parameter to irscan
Change-Id: I89e0422456c59ee86c4b6d9bd3b3ad32051b31ac
Signed-off-by: Evan Hunter <ehunter@broadcom.com>
Reviewed-on: http://openocd.zylin.com/831
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-07-01 08:37:14 +00:00
Robert Jarzmik 18e15390df drivers/jtag: usb_blaster add pin controls
Add pin controls (pin6 and pin8). These pins can be
controled either :
 - with a fixed value (0 or 1)
 - by TRST or SRST reset signal (driven low when signal
 activated).

Change-Id: Ie6a3e57fc6ba6a38fdb9a009c976e3febab8f578
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Reviewed-on: http://openocd.zylin.com/1448
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Tested-by: jenkins
2013-06-29 10:05:59 +00:00
Antonio Borneo f550277482 flash/nor/spi: uniform all hex data to lowercase
Change-Id: I3daee7218283e521bf490993dba02a8658540951
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/1453
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-21 15:37:40 +00:00
Antonio Borneo 6ea76e98da flash/nor/spi: add flash Micron n25q064
Change-Id: Ic39bb6d020767cece2eaa4e194071be8b002ece4
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/1452
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-21 15:37:30 +00:00
R. Diez 0910f1a507 Bus Pirate driver: Small assorted fixes.
Fixes are:
- Discard any stale data from the previous connection.
- Disable CR/LF translation on the (virtual USB) serial port.
- Increase the average USB packet size. The 1 KiB buffer was underutilised.
- Option "buspirate_speed fast" now works out of the box.
- Some extra comments, error checking, etc.

Change-Id: I72c49d943a8ce9c5e5d1644ef90cb1482f93c618
Signed-off-by: R. Diez <rdiezmail-openocd@yahoo.de>
Reviewed-on: http://openocd.zylin.com/1437
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-21 11:25:26 +00:00
Andreas Fritiofson 9f1616d2b5 stm32f2x: Correct calculation of number of 128k sectors.
Fixes regression introduced in 9785f51f that caused write outside
allocated memory during probe of devices with <1024K flash.

Reported-by: Alexander Pakhomov <ker0sin@yandex.ru>
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Change-Id: Ifba8833e436064624efbf678162538fd351a5702
Reviewed-on: http://openocd.zylin.com/1450
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-21 11:21:09 +00:00
Spencer Oliver 601e35571c build: add missing configure quotes
Change-Id: I14abb24292d4c2ff088c7b95773f73ceac3287cd
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1445
Tested-by: jenkins
2013-06-14 20:28:16 +00:00
Spencer Oliver 0b5bd6b01e build: fix incorrect configure quotes
Change-Id: I427035df1ab2bfb2ec6ac8fafc9683f7d3e3bf06
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1444
Tested-by: jenkins
2013-06-14 20:27:52 +00:00
Brent Roman c60deb582d hla: Add Simulated DCC register for target communicaton
Change-Id: I193be169059caba661e46de8081d7e92f92cafee
Signed-off-by: Brent Roman <brent@mbari.org>
Reviewed-on: http://openocd.zylin.com/1364
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-14 11:18:57 +00:00
Andreas Fritiofson b8c44b3fd7 [RFC] mips: Enable bulk write optimization for all writes
mips_m4k_bulk_write_memory was only called from target_write_buffer as an
optimization when the word count was large enough.

Remove mips_m4k_bulk_write_memory from the target type, causing the default
implementation to call the regular mips_m4k_write_memory instead.

Perform the dispatch to bulk write in mips_m4k_write_memory, enabling the
optimization for target_write_memory() writes with size 4, in addition to
target_write_buffer() writes.

It also enables making the choice of bulk write vs regular write
specifically for the architecture and not relying on the generic target
code to make a sensible decision.

Change-Id: I295f21a67ceaa195802403f2518ea2e0a025c1c7
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/1215
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Tested-by: jenkins
2013-06-12 20:11:36 +00:00
Spencer Oliver 8e4c80c17d cfg: add stm32 flash driver alias
This will enable the user to use either name when calling flash driver cmds.

For example the stm32f3x family use the same flash driver as the stm32f1x, so
the user has to use 'stm32f1x mass_erase 0' which can be confusing.
Now the user can also use 'stm32f3x mass_erase 0' with the same result.

Change-Id: I14280674c8dfa2ce1c01e327af7f38e36150462c
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1428
Tested-by: jenkins
2013-06-12 14:44:14 +00:00
Giuseppe Barba d70f86e7da stm32w: add STM32w108xx generic configuration
Add generic TCL configuration for STM STM108Wxx chips.

Change-Id: I981cdccb78833f442c3be4188c8c023064067e4e
Signed-off-by: Giuseppe Barba <giuseppe.barba@gmail.com>
Reviewed-on: http://openocd.zylin.com/1439
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-12 14:43:23 +00:00
Spencer Oliver 7655e15ea5 stm32: add new stm32f0 device id
updated from RM0091 rev4.

Change-Id: Ic5e46229b85ce3974ef3016724d29a94037ac577
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1435
Tested-by: jenkins
2013-06-12 14:42:05 +00:00
Spencer Oliver 3a8a6e5c3e cortex_a: remove memory leak on failure
If mem_ap_sel_write_atomic_u32 fails then tmp_buff may not be released.
Detected by clang.

Change-Id: I3d5416bd47d0eea61f61ec02ac5e43c82f114108
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1433
Tested-by: jenkins
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2013-06-12 14:41:43 +00:00
Spencer Oliver bbc193ef8d str9: ignore boundary scan version
Ignore version of Boundary Scan TAP in newer revisions of the str9.

Change-Id: I6e205f8c731f07078c469e686025857c180f3a6d
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1436
Tested-by: jenkins
2013-06-12 14:41:28 +00:00
Jim Norris 6ff1dc92fd Change variable scope.
Change scope of the variable gdb_reg_list_idx from global to module.

Change-Id: Ib8273c0769c11c1d5a338e4711efbddb8e8a0243
Signed-off-by: Jim Norris <u17263@att.net>
Reviewed-on: http://openocd.zylin.com/1441
Tested-by: jenkins
Reviewed-by: Øyvind Harboe <oyvindharboe@gmail.com>
2013-06-12 14:41:04 +00:00
Paul Fertser 6be2a55bde configure: remove --enable-libusb0 option, rework libusb selection
This makes libusb handling more consistent: if any driver requires
libusb, first check for libusb-1 availability, if not found and
libusb0 is ok for this case, try libusb0.

A user-visible bug fixed by this is that when a user was selecting a
driver that required libusb-1 but was lacking the necessary dev files
or libraries, configure didn't complain (but the build was failing of
course).

--enable-stlink doesn't really require libusb-1 but since it's using the
same automake symbol HLAADAPTER, ti_icdi is getting built too which needs
libusb1 unconditionally. Since using libusb-0.1 makes little sense anyway,
leave that as is.

Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Change-Id: I630a4ad9e4583743d45b2233bf5d8f4e5c0aab82
Reviewed-on: http://openocd.zylin.com/1434
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-12 14:40:29 +00:00
Paul Fertser 71ee5f6b5f libusb1_common, ftdi: clarify libusb_open error message
Print a user-friendly message when libusb_open() fails, e.g.
Error: libusb_open() failed with LIBUSB_ERROR_ACCESS
when there's a permissions problem.

Also output a configure warning if libusb older than 1.0.9 is detected.

Change-Id: I800f71f06672fe06c0a98a4e469f853b5021bcfe
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1430
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-12 14:40:16 +00:00
Paul Fertser 703781c5ab ftdi: config for TUMPA
Add a config file for TIAO USB Multi-Protocol Adapter.

Based on schematics from http://www.mediafire.com/?zv158nnx1gv0cy2

Cc: Volkan K <volkan-k@users.sourceforge.net>
Change-Id: I0dfd93b0b1e558e4ccd7c94c005c099947ec94df
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1438
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2013-06-12 10:16:18 +00:00
Spencer Oliver 45bafc5c99 build: fix incorrect GPL address from last commit
962b3eb40c included the old GPL address.

Change-Id: I7affbdc3fc1c9251ea90796ab9eeef4d56ba4308
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1440
Tested-by: jenkins
Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2013-06-10 20:51:42 +00:00
Paul Fertser 962b3eb40c Add BCM2835 (as found in Raspberry Pi) interface driver
This adds support for JTAG programming by bitbanging GPIOs exposed on
the RaspberryPi's expansion header.

Tested by connecting directly to an STM32VLDiscovery board, without any
additional circuity. I observed maximum about 4MHz on the TCK pin with an
old analogue 'scope and about 100kHz when setting the speed to 100kHz.
Busyloop waiting is needed because even with a single 0ns nanosleep call
(with FIFO priority) it lowers the TCK speed to ~30kHz which is way too low
to be useful.

The speed testing with adapter_khz 2000 gave the following results:
sudo chrt -f 1 nice -n -19 ./src/openocd \
     -f interface/raspberrypi-native.cfg \
     -c "set WORKAREASIZE 0x2000" \
     -f target/stm32f1x.cfg -c "adapter_khz 2000"

wrote 131072 bytes from file random.bin in 3.973677s (32.212 KiB/s)
dumped 131072 bytes in 1.445699s (88.538 KiB/s)

This is 3.7 times faster for writing and 14.3 times faster for reading
compared to the generic sysfsgpio driver; probably the writing speed is
limited by the target itself here and reading speed might be considerably
higher too with appropriate connection and a capable target.

BCM2835 name is choosen over BCM2708 because the published peripherals
datasheet uses the particular model name and not family name.

Change-Id: Ib78168be27f53c2a3c88c3dd8154d1190c318c78
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/758
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-10 09:39:48 +00:00
Spencer Oliver 08d4411b59 update files to correct FSF address
Change-Id: I429f7fd51f77b0e7c86d7a7f110ca31afd76c173
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1426
Tested-by: jenkins
Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2013-06-05 19:52:42 +00:00
Ryan Corbin 76b3563860 Added OpenJTAG Driver
Updated OpenJTAG driver from www.openjtag.org to work with latest version of OpenOCD.

Change-Id: I2917f4e5835fb9ca5265e81dc38515fa97ae9503
Signed-off-by: Ryan Corbin <corbin.ryan@gmail.com>
Reviewed-on: http://openocd.zylin.com/1406
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-05 19:52:15 +00:00
Hsiangkai Wang cf8a3c3d70 nds32: add new target type nds32_v2, nds32_v3, nds32_v3m
Add target code for Andes targets.

Change-Id: Ibf0e1b61b06127ca7d9ed502d98d7e2aeebbbe82
Signed-off-by: Hsiangkai Wang <hsiangkai@gmail.com>
Reviewed-on: http://openocd.zylin.com/1259
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-05 19:27:35 +00:00
Hsiangkai Wang ceb402dc9e aice: add Andes AICE support
Andes AICE uses USB to transfer packets between OpenOCD and AICE.
It uses high-level USB commands to control targets instead of using
JTAG signals. I define an interface as aice_port_api_s. It contains
all basic operations needed by target-dependent code.

Change-Id: I117bc4f938fab2732e44c509ea68b30172d6fdb9
Signed-off-by: Hsiangkai Wang <hsiangkai@gmail.com>
Reviewed-on: http://openocd.zylin.com/1256
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-05 19:27:23 +00:00
Robert Jarzmik 8890ce3469 drivers/jtag: rewrite usb_blaster driver
Rewrite the Altera USB Blaster dongle driver :

 - make extensive use of byte-shift mode, to improve JTAG
   speed.
   This is the main reason of the rewrite. It improves the
   memory dumps with a factor 3 at least, and upload 100
   times, from 1 kBytes/sec to 100 kBytes/sec with a
   USB-Blaster connected to an Altera Virtual JTAG TAP +
   OpenRISC CPU.

 - split the low level API part (between FTDI and FTD2xx)
 from core driver, so that in the future, if both libftdi
 and ftd2xx can coexist, the driver will be able to switch
 dynamically from one access to the other.

Change-Id: I2ee9cedf4a5eb27501f337993ee0cdee52517e7c
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Marek Czerski <ma.czerski@gmail.com>
Tested-by: Franck Jullien <franck.jullien@gmail.com>
Reviewed-on: http://openocd.zylin.com/467
Tested-by: jenkins
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-by: Alexandre Becoulet <alexandre.becoulet@free.fr>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-04 20:00:42 +00:00
Spencer Oliver 452df0371e cortex_m: print 'Cortex-M' rather than 'Cortex-M3'
This file is used by all the Cortex-M family not just Cortex-M3.

Change-Id: Ie8680535b220c66bb8fcd862510407a46a73e8a0
Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/1429
Tested-by: jenkins
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2013-06-03 21:31:48 +00:00
Andreas Fritiofson 434eca2315 cortex_a: fix FTBS on ARM due to alignment issues
Native compilation on RaspberryPi with
gcc (Debian 4.6.3-1) 4.6.3
Target: arm-linux-gnueabi

ends with error:

cortex_a.c: In function 'cortex_a8_read_apb_ab_memory':
cortex_a.c:2063:40: error: cast increases required alignment of target type [-Werror=cast-align]
cc1: all warnings being treated as errors

Also check for malloc failure.

This patch is compile-tested only.

Change-Id: I580c505424d03ac3a565de54182db22277c52ac1
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/1369
Tested-by: jenkins
Reviewed-by: Freddie Chopin <freddie.chopin@gmail.com>
Reviewed-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-03 11:06:38 +00:00
Paul Fertser f43c23090e rlink: fix speed table generation
The speed table generation (by using explicit
make -f Makefile.rlink) was broken since
865efd828a Dec 2 2009 which did a bunch of
renaming and included hand-editing of a generated rlink_speed_table.c file.

This patch is compile-tested, i.e. the new generated rlink_speed_table.c
links fine with the rlink driver.

Change-Id: I1789a2f2f5bf20183b772d55c55fe68a0bd05cf5
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1431
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-06-03 10:59:59 +00:00
William M.A. Traynor 7d8b046187 user guide: Update the ZY1000 description.
As per request from Peter at Ultimate Solutions, updated the
description of the ZY100 Stand-alone JTAG probe.

Signed-off-by: Bill Traynor <wmat@alphatroop.com>

Change-Id: Ia5c0b9a7261becd524a02aba1b22a98a2e09a4c9
Signed-off-by: William M.A. Traynor <wmat@alphatroop.com>
Reviewed-on: http://openocd.zylin.com/1357
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-30 22:43:25 +00:00
Paul Fertser e4d543ffc7 tools: add sample remote_bitbang sysfsgpio server
This adds a sample server that implements remote_bitbang protocol,
based on sysfsgpio interface driver.

Change-Id: I17633e91f819ab7b806606e1a1c38d5366ab4598
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1403
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-29 14:41:17 +00:00
Paul Fertser afca2e817d cortex_m, hla_target: do not try asserting SRST if it's not present
This should cover all the cases when RESET_SRST_NO_GATING is set
without RESET_HAS_SRST. This might happen when RESET_SRST_NO_GATING is
automatically set by a target code (and not from tcl).

However, there're some other places (mips_m4k, arm7_9_common) where
adding RESET_SRST_PULLS_TRST would lead to trying to use SRST even if
it's not present. Currently it's impossible for the user to enable
that flag without enabling SRST.

Change-Id: Ib1c6f68feed0b8057d55afd5f260bb22ab332ced
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1405
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-29 14:39:26 +00:00
Paul Fertser 9a231e295c interface/ftdi: remove "untested" warning from DP Busblaster
This is reported as working by mitsakos on IRC.

Change-Id: I26b97779c3e8e237c5b3996aa81183031b12ec0c
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1419
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-29 14:32:29 +00:00
Paul Fertser 2aada5b8d9 targets: fix target_type name for Cortex-A targets
Commit d9ba56c295 did a bunch of
renaming of cortex_a8 to cortex_a, including the names in config
files. However that introduced a regression as the name in target_type
struct remained unchanged.

This adds the last missing bit: actual renaming of the target name as
understood by OpenOCD.

Also change the (hopefully) last instance of using it in the supplied
config files, namely from imx6.cfg.

Change-Id: Ib9289fc6d946630133ec6e36c20015ccb50acf61
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1420
Tested-by: jenkins
Reviewed-by: Chris Johns <chrisj@rtems.org>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-28 08:48:45 +00:00
Andreas Fritiofson 70a2ffac8e remote_bitbang: De-duplicate init code and clean up on error
Change-Id: I8be413a9e1683f96f835232f9ff25d9bd42099de
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/1380
Tested-by: jenkins
Reviewed-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-10 14:46:55 +00:00
Andreas Fritiofson 00ba179dbc remote_bitbang: Convert to use getaddrinfo()
Since gethostbyname() is deprecated and inconvenient, rewrite to use
getaddrinfo() using an implementation more or less copied from its man
page. This automatically enables support for IPv6.

This also fixes a FTBFS on ARM due to alignment issues.

Change-Id: I990a49506cac4b26faf77587937e506138371f7c
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/1379
Reviewed-by: Paul Fertser <fercerpav@gmail.com>
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-10 14:46:44 +00:00
Brandon Warhurst 232af6cc9b Added functionality to the SYS_SYSTEM semihosting call.
There seems to be a few missing semihosting calls.  I
am not sure why this one is actually missing, since it
seems simple enough to implement.  It was tested using
an HTC HD7 connected to openocd through a "home brew"
ftdi 4232H board.

Change-Id: Ie17dc96c6d48227a3dc9ff1e21201a85498a10b1
Signed-off-by: Brandon Warhurst <roboknight@gmail.com>
Reviewed-on: http://openocd.zylin.com/1345
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-10 14:20:08 +00:00
Ravaz a07a3d2d44 Added: RTOS awareness for embKernel
Change-Id: I98b60f50a5fc486bda83b83ad7ec73826ee11607
Signed-off-by: Ravaz <embkernel@gmail.com>
Reviewed-on: http://openocd.zylin.com/1334
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-10 14:19:00 +00:00
Paul Fertser 49af0788e9 stm32 configs: use 4kB working area size by default
This is needed for configs that might be used with the cheapest
STM32F100 parts that have only 4kB SRAM.

Restrictions for the other STM32 families are verified to be set
appropriately.

Change-Id: I1ad2370435015604db9f27c1a76c153480311a28
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: http://openocd.zylin.com/1378
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2013-05-10 14:17:56 +00:00