kinetis: update support for all program flash granularities
Updates the Kinetis NOR flash support to handle all known block and sector
sizes. Previously only 2kiB sectors were hard-coded, now all four known
combinations non-volatile sector sizes are supported.
The premise of separating Kinetis Program Flash (PFLASH) from FlexNVM is
also introduced. This means each "block" of flash (in Freescale terms) is
treated as a bank in OpenOCD. Correspondingly, the existing board
configuration for the TWR-K60M512 eval system is updated to recognize two
banks instead of one.
A board config for the TWR-K60F120M is also added.
Bank and sector erase and programming has been checked with both of the
mentioned eval boards.
Change-Id: Iae2d10ebf8f548d0a3698df5430bbbe1ccadc58a Signed-off-by: Christopher Kilgour <techie@whiterocker.com>
Reviewed-on: http://openocd.zylin.com/663 Tested-by: jenkins Reviewed-by: Mathias Küster <kesmtp@freenet.de> Reviewed-by: Jan Dakinevich <jan.dakinevich@gmail.com> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Some versions of Segger's software do not select JTAG interface by default.
Do it in the intial setup.
Firmware version check code still present, with updated set of unsupported.
Note from Segger:
Alright, we were not aware of that OpenOCD does not select the interface
before it starts communicating with the target. A debugger should always
select the appropriate target interface before it starts communicating with the target,
since otherwise it could also happen that a previous session with another debugger
had selected SWD and the interface was not switched again by OpenOCD.
Change-Id: I5b4eab7e0e3625ec32be75a36d89e16d17e899bf Signed-off-by: Alexander Osipenko <sipych@gmail.com>
Reviewed-on: http://openocd.zylin.com/667 Tested-by: jenkins Reviewed-by: Xiaofan <xiaofanc@gmail.com> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
OpenOCD does not work with the latest firmware versions
of Segger J-Link.
Latest working version: V4.42c
Unsupported versions: 4.44 to 4.46f, 4.20 to 4.30
Older versions of firmware can be found here:
http://www.segger.com/j-link-older-versions.html
The firmware versions does not correspond directly with
"Software and documentation pack for Windows", it may be
distinguished by the "compile" date in the information string.
Print an warning message if unsupported firmware version detected.
Change-Id: Id7d1f965b8ce2fdbcd0026a85ddd093e2fa48720 Signed-off-by: Alexander Osipenko <sipych@gmail.com>
Reviewed-on: http://openocd.zylin.com/666 Tested-by: jenkins Reviewed-by: Xiaofan <xiaofanc@gmail.com> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Liviu Ionescu [Tue, 29 May 2012 11:52:04 +0000 (14:52 +0300)]
docs: J-Link commands added to the manual
The J-Link related commands and configuration commands were added
to the "8.2 Interface Drivers" section of the manual.
(previously they were enumerated as comments).
The 'jlink pid' was marked as Config all other as Command.
A draft of a compatibility note was added, but probably
a table would be more appropriate.
Liviu Ionescu [Tue, 29 May 2012 16:41:02 +0000 (19:41 +0300)]
tools: initial.sh fixed to accept spaces in current path
When changing the path to the hooks folder, the path needs to be
surrounded by quotation marks, to avoid failures when the current
path contains spaces (not only legal, but a common case on
Mac OS X).
Peter Stuge [Mon, 14 May 2012 15:47:09 +0000 (17:47 +0200)]
docs: Fix incorrect -rtos option values
Commit 9ca1592cb9fe4e61ee5bc327345fdfc254c9fe13 started on documentation
for the -rtos option, but some of the documented values were incorrect so
we'll clean up the mess here.
Spencer Oliver [Fri, 11 May 2012 08:39:58 +0000 (09:39 +0100)]
stlink: add armv7m stlink handling
This enables us to better handle some of the low level functions that the
stlink does not support. It also enables us to share a few more of the
standard cortex_m3 functions if necessary.
Change-Id: I7a2c57450122012ec189245d8879d8967913e00e Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-on: http://openocd.zylin.com/637 Tested-by: jenkins
Aurelien Jacobs [Tue, 8 May 2012 18:53:18 +0000 (20:53 +0200)]
cfi: fix write_bank segfault with spansion flash on armv7m
cfi_spansion_write_block() passes an arm_algorithm struct to
target_run_algorithm() which in turn calls armv7m_start_algorithm()
which expect an armv7m_algorithm struct.
As armv7m_algorithm is bigger than arm_algorithm, when
armv7m_start_algorithm() writes in the struct, it overrun the buffer,
writting junk on the stack, which latter on generates a segfault.
This patch ensure we use a properly sized armv7m_algorithm struct
when the target is an armv7m.
Bill Traynor [Tue, 8 May 2012 13:32:35 +0000 (09:32 -0400)]
cfg: Deleted duplicate busblaster.cfg and renamed original.
The busblaster.cfg was contributed on April 23, 2012 and is a
duplicate of dp_busblaster.cfg that was contributed on Oct. 23,
2011. Therefore, deleting the second version. Also, renaming
the original dp_busblaster.cfg to simply busblaster.cfg, as this
name is more concise.
Change-Id: Iccb1f10f53dbbb248b1ff4c6295eaf67c32247c1 Signed-off-by: Bill Traynor <wmat@alphatroop.com>
Reviewed-on: http://openocd.zylin.com/622 Tested-by: jenkins Reviewed-by: Peter Stuge <peter@stuge.se>
Bill Traynor [Mon, 7 May 2012 18:38:16 +0000 (14:38 -0400)]
cfg: add default pid/vid pair to beaglebone board cfg.
The newer versions of BeagleBone boards use the default vid/pid
pair for FT2232 debugging. Please see the following README:
http://beagleboard.org/static/beaglebone/latest/README.htm
On revision A3/A4 boards, the VID/PID were chosen to match the
TI XDS100v2 (0x0403/0xA6D0). On A5 and newer revisions when we've
given the authors of CCS the chance to update their software, the
generic FTDI VID/PID (0x0403/0x6010) will be used to simplify
installation of drivers for systems already having those drivers.
Change-Id: I44228eb2029162f23d084eb05bcfef39e615668d Signed-off-by: Bill Traynor <wmat@alphatroop.com>
Reviewed-on: http://openocd.zylin.com/619 Tested-by: jenkins Reviewed-by: Peter Stuge <peter@stuge.se>
Spencer Oliver [Thu, 19 Apr 2012 14:51:14 +0000 (15:51 +0100)]
stlink: support srst reset
This adds the ability to support srst reset for the stlink/v2.
stlink/v1 will fallback to using SYSRESETREQ which is a full reset - including peripherals.
To enable the use of the srst add the following to your cfg:
reset_config srst_only
SAM3X - Added support for at91sam3x8h-ES, fixed CIDR for ES2 and production
The first available devkits for the at91sam3x8h had the ES device populated.
The ES device had an error in the CIDR, specifically in the last byte of
which the upper 3 bits identifies the chip family - cortex-m3, arm7tdmi etc.
The problem was fixed on the ES2 devices - Thanks to Pat Hickey for giving me
the heads-up.
Change-Id: I13dd7fbe0cffaf76f948188c9459dc3cf4435570 Signed-off-by: Olivier Schonken <olivier.schonken@gmail.com>
Reviewed-on: http://openocd.zylin.com/575 Tested-by: jenkins Reviewed-by: Jim Norris <u17263@att.net> Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
The SAM4S processors still suffer from the "6 waitstates needed
to program device" errata.
Other relevant changes are:
1. Address of flash memory starts at 0x400000.
2. EWP (Erase page and write page) only works for the first two 8KB "sectors"
3. Because of the EWP not working for all the sectors, normal page writes have
to be used. The default_flash_blank_check is used to check if lockregions
should be erased.
4. The EA (Erase All) command takes 7.3s to complete. (Previous timeout was
500 ms)
5. There are 128 lockable regions of 8KB each.
Implemented default blank checking, and page erase for load_image scenarios.
This is to compensate for the EWP flash commands only working on the
first 2 8KB sectors.
Allen Martin [Sat, 21 Apr 2012 03:33:28 +0000 (20:33 -0700)]
cfg: Add interface config for Dangerous Prototypes Bus Blaster
This is a FT2232 based USB JTAG dongle
Change-Id: Ibed773a23b6446df62fe4eac16c27fb2d741f4c3 Signed-off-by: Allen Martin <amartin@nvidia.com>
Reviewed-on: http://openocd.zylin.com/589 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Bill Traynor [Sun, 22 Apr 2012 13:47:37 +0000 (09:47 -0400)]
UserGuide: Fixed link to Wiggler2 project.
In section '2.9 IBM PC Parallel Printer Port based' fixed link to
the Wiggler2 project and removed the alternate URL text to retain
style consistency with the other URLs in the document:
http://www.ccac.rwth-aachen.de/~michaels/index.php/hardware/armjtag
Change-Id: I879db1c6eaf683ca6475a0f466f987087c9d60d0 Signed-off-by: Bill Traynor <wmat@alphatroop.com>
Reviewed-on: http://openocd.zylin.com/593 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Bill Traynor [Sun, 22 Apr 2012 13:54:02 +0000 (09:54 -0400)]
UserGuide: Fixed link to ST flashlink.
In section '2.9 IBM PC Parallel Printer Port Based' fixed link to
ST's flashlink PDF and removed alternate URL text:
http://www.st.com/internet/com/TECHNICAL_RESOURCES/TECHNICAL_LITERATURE/
DATA_BRIEF/DM00039500.pdf
Change-Id: I99702dd00d4145784baee1f63b5998bf79e06678 Signed-off-by: Bill Traynor <wmat@alphatroop.com>
Reviewed-on: http://openocd.zylin.com/594 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Uwe Hermann [Sun, 15 Apr 2012 16:42:39 +0000 (18:42 +0200)]
Split olimex_stm32_h107.cfg.
Use one board file per eval board, so that the filename matches the
exact board the user has / wants to use. Merging different boards into
one file is confusing.
Change-Id: I7c50233924a87a913723d7215c4851039c2971bc Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Reviewed-on: http://openocd.zylin.com/566 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Bill Traynor [Thu, 19 Apr 2012 18:16:23 +0000 (14:16 -0400)]
UserGuide: Fixed link to Raisonance RLINK.
In section 2.6 USB JLINK based, fixed link to RLINK:
http://www.mcu-raisonance.com/~rlink-debugger-programmer__microcontrollers__tool
~tool__T018:4cn9ziz4bnx6.html
Change-Id: I15f7a1b68b851054e07eefc07a50b4590ebce677 Signed-off-by: Bill Traynor <wmat@alphatroop.com>
Reviewed-on: http://openocd.zylin.com/588 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Bill Traynor [Wed, 18 Apr 2012 20:56:10 +0000 (16:56 -0400)]
HACKING: Fix instruction for git pull --rebase
When following the Patch Guidelines step by step,
an error occurs at step 6.
"git pull --rebase origin/master" results in the error:
fatal: 'origin/master' does not appear to be a git repository
Removing the / seems to fix this.
Change-Id: I4e2fa23c60654abeaebd3b25a8c8375aa07b0abd Signed-off-by: Bill Traynor <wmat@alphatroop.com> Signed-off-by: Peter Stuge <peter@stuge.se>
Reviewed-on: http://openocd.zylin.com/574 Reviewed-by: David Anders <danders.dev@gmail.com> Tested-by: jenkins
David Anders [Wed, 18 Apr 2012 20:12:24 +0000 (15:12 -0500)]
pandaboard: add initial TCL support for pandaboard-es
add initial TCL support for the pandaboard-es which is
based on the omap4460 from Texas Instruments.
Change-Id: Ic63588721487feb95e7cb3d41cfaab0d2f181766 Signed-off-by: David Anders <danders.dev@gmail.com>
Reviewed-on: http://openocd.zylin.com/573 Tested-by: jenkins Reviewed-by: Peter Stuge <peter@stuge.se>
David Anders [Wed, 18 Apr 2012 19:42:50 +0000 (14:42 -0500)]
omap4460: add initial TCL support for the omap4460 es1.0
this patch adds the initial support for the omap4460 es1.0
version which is similar to the omap4430 and used on the
pandaboard-es.
Change-Id: If885f7d9f8809929bd799786b539e4f499fa3478 Signed-off-by: David Anders <danders.dev@gmail.com>
Reviewed-on: http://openocd.zylin.com/572 Tested-by: jenkins Reviewed-by: Peter Stuge <peter@stuge.se>