openocd.git
8 years agoNAND/DAVINCI: remove private "target" copy
Antonio Borneo [Fri, 31 Dec 2010 11:46:03 +0000 (19:46 +0800)]
NAND/DAVINCI: remove private "target" copy

Remove "target" form private data, and use
common one in struct nand_block.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNAND/AT91SAM9: remove private "target" copy
Antonio Borneo [Fri, 31 Dec 2010 11:46:02 +0000 (19:46 +0800)]
NAND/AT91SAM9: remove private "target" copy

Remove "target" form private data, and use
common one in struct nand_block.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNAND/TCL: prepare for common "target" reference
Antonio Borneo [Fri, 31 Dec 2010 11:46:01 +0000 (19:46 +0800)]
NAND/TCL: prepare for common "target" reference

Every NAND driver keeps private copy of "target"
structure.
Prepare infostructure to move private "target"
copy in common/shared struct nand_device.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNAND/TCL: fix segfault on syntax error
Antonio Borneo [Fri, 31 Dec 2010 11:18:11 +0000 (19:18 +0800)]
NAND/TCL: fix segfault on syntax error

Fix segfault if incomplete command "nand device dummy"
is executed.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNAND/CORE: Comment use of alive_sleep()
Antonio Borneo [Fri, 31 Dec 2010 11:18:10 +0000 (19:18 +0800)]
NAND/CORE: Comment use of alive_sleep()

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNAND/CORE: Replace decimal dot in messages
Antonio Borneo [Fri, 31 Dec 2010 11:18:09 +0000 (19:18 +0800)]
NAND/CORE: Replace decimal dot in messages

Table of NAND devices reports operating voltage.
Replace comma with proper decimal dot.

Øyvind: "." is correct for UK/US, but incorrect for
many other languages. OpenOCD is not localized at this
point, so sticking to "." for US/UK should be OK.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoflash/nand: review NAND driver interface
Antonio Borneo [Fri, 31 Dec 2010 11:18:08 +0000 (19:18 +0800)]
flash/nand: review NAND driver interface

From struct nand_flash_controller :
- remove unused field register_commands;
- remove field controller_ready, exported but
  never referenced.
Remove dead code pointed by controller_ready.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoCORTEX A8: Fix broken CPU identification
Marek Vasut [Thu, 30 Dec 2010 03:54:24 +0000 (04:54 +0100)]
CORTEX A8: Fix broken CPU identification

This patch fixes the issue where the OMAP CPU (and possibly others) was mistaken
for iMX51 and therefore had misadjusted debug base.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
8 years agoCompilation Warnings on OS X 10.5
Andrew MacIsaac [Wed, 29 Dec 2010 20:15:48 +0000 (12:15 -0800)]
Compilation Warnings on OS X 10.5

I received a number of "-Wshadow" related warnings (treated as errors) while
trying to build on OS X Leopard.  In addition, there were two miscellaneous
other warnings in the flash drivers.  Attached are two patches which correct
these issues and the commit messages to accompany them.

My system has the following configuration (taken from uname -a):

Darwin 9.8.0 Darwin Kernel Version 9.8.0: Wed Jul 15 16:55:01 PDT 2009;
root:xnu-1228.15.4~1/RELEASE_I386 i386

=== Werror_patch.txt Commit Message ===
compilation: fixes for -Wshadow warnings on OS X

These changes fix -Wshadow compilation warnings on OS X 10.5.8

Compiled with the following configure command:

../configure --prefix=/usr/local --enable-maintainer-mode --enable-jlink
--enable-ft2232_libftdi

=== flash_patch.txt Commit Message ===
compilation: fixes for flash driver warnings on OS X

These changes fix two compilation warnings on OS X 10.5.8:

../../../../src/flash/nor/at91sam3.c:2767: warning: redundant redeclaration
of 'at91sam3_flash'
../../../../src/flash/nor/at91sam3.c:101: warning: previous declaration of
'at91sam3_flash' was here

and

../../../../src/flash/nor/stmsmi.c:205: warning: format not a string literal
and no format arguments

Compiled with the following configure command:

../configure --prefix=/usr/local --enable-maintainer-mode --enable-jlink
--enable-ft2232_libftdi
===

Andrew

8 years agowarning: fix warning where GCC didn't catch a doubly declared global structure
Øyvind Harboe [Wed, 29 Dec 2010 21:14:43 +0000 (22:14 +0100)]
warning: fix warning where GCC didn't catch a doubly declared global structure

Why hasn't earlier versions of GCC caught this? Bug?

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agowarnings: use more 'const' for char *
Øyvind Harboe [Wed, 29 Dec 2010 21:07:21 +0000 (22:07 +0100)]
warnings: use more 'const' for char *

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agotarget: do not expose error numbers to users
Øyvind Harboe [Wed, 29 Dec 2010 19:58:30 +0000 (20:58 +0100)]
target: do not expose error numbers to users

error numbers are only reported at DEBUG log levels and
used internally, they are not part of the user interface.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoinitial SWD transport (SWD infrastructure #2)
David Brownell [Sat, 25 Dec 2010 02:50:41 +0000 (18:50 -0800)]
initial SWD transport (SWD infrastructure #2)

This piggy backs on JTAG so it's not yet pretty, but that
seems unavoidable so far given today's OpenOCD internals.

SWD init and data transfer  are unfinished and untested, but
that should cause no regressions, and will be addressed by
the time drivers start using this infrastructure.  Checking
in whould get the code working better sooner, and turn up any
structural/architectural issues while they're easier to fix.

The debug adapter drivers will provide simple SWD driver
structs with methods that kick in as needed (instead of JTAG).
So far just one adapter driver has been updated (not yet
ready to use or circulate).

The biggest issues are probably
  - fault handling, where the ARM Debug Interface V5 pipelining
    needs work in both JTAG and SWD modes and
  - missing  rewrite of block I/O code to work on both of our
Cortex-ready transports (Current code is  hard-wired to JTAG);
relates also to the pipelining issue.
  - omitted support to activate/deactivate SWO/SWV trace (this is
    technically trivial, but configuring what to trace is NOT.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
----

 doc/openocd.texi        |   17 ++
 src/jtag/core.c         |    3
 src/jtag/interface.h    |    4
 src/jtag/jtag.h         |    2
 src/jtag/swd.h          |  114 +++++++++++++++++++
 src/jtag/tcl.c          |    2
 src/target/adi_v5_swd.c |  281 ++++++++++++++++++++++++++++++++++++++++++++++--
 src/target/arm_adi_v5.c |    8 +
 src/target/arm_adi_v5.h |    3
 9 files changed, 425 insertions(+), 9 deletions(-)

8 years agostm32x : always use valid flash base address
Spencer Oliver [Thu, 23 Dec 2010 13:10:15 +0000 (13:10 +0000)]
stm32x : always use valid flash base address

This change matches the previous behaviour of using the known
flash address.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agoflash: print flash bank name on flash info cmd
Spencer Oliver [Thu, 23 Dec 2010 12:39:22 +0000 (12:39 +0000)]
flash: print flash bank name on flash info cmd

The flash bank name is a required element in adding flash banks,
however other than looking at the config file there is no way of
getting the name used in openocd.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agostm32: fix reversed option byte write
Spencer Oliver [Thu, 23 Dec 2010 12:06:12 +0000 (12:06 +0000)]
stm32: fix reversed option byte write

This has been a long standing bug that has never been spotted.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agostm32: update option bytes for stm32xl family
Spencer Oliver [Thu, 23 Dec 2010 12:04:53 +0000 (12:04 +0000)]
stm32: update option bytes for stm32xl family

add supoort for xl family boot bank option.
The option byte handling will be cleaned up in a later patch.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agostm32: add stm32 xl family flash support
Spencer Oliver [Wed, 22 Dec 2010 17:20:11 +0000 (17:20 +0000)]
stm32: add stm32 xl family flash support

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agostm32: add dual flash bank support
Spencer Oliver [Wed, 22 Dec 2010 17:18:14 +0000 (17:18 +0000)]
stm32: add dual flash bank support

This patch adds the initial dual flash bank support for devices such
as the stm32xl family.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocontrib: change stm32 flash loader extension
Spencer Oliver [Fri, 10 Dec 2010 10:35:03 +0000 (10:35 +0000)]
contrib: change stm32 flash loader extension

As the stm32 flash loader now uses the preprocessor change extension
so that it used by default.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agolpc2148: redo to the new target configuration scheme
Øyvind Harboe [Tue, 21 Dec 2010 19:59:12 +0000 (20:59 +0100)]
lpc2148: redo to the new target configuration scheme

Define a proc which PCBs can easily override.

Also demonstrates how to add multiple TAP exepcted-id's
using arguments.

Added 0x3f0f0f0f as expected TAP-id. Old LPC2148 silicon
I happened to have on my desk?

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoconfig: add init_targets proc that is executed just before init
Øyvind Harboe [Sun, 19 Dec 2010 10:24:51 +0000 (11:24 +0100)]
config: add init_targets proc that is executed just before init

this allows configuration scripts to export a init_targets proc
rather than setting up the target directly.

This allows for new conventions in how to set up target vs. board
script and how to transfer default settings between board and
target scripts.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agobootstrap: by default the submodules are initialized
Øyvind Harboe [Wed, 22 Dec 2010 13:29:34 +0000 (14:29 +0100)]
bootstrap: by default the submodules are initialized

use "nosubmodule" to skip setting up submodules.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoserver: remove error value from LOG_INFO
Øyvind Harboe [Tue, 21 Dec 2010 13:07:17 +0000 (14:07 +0100)]
server: remove error value from LOG_INFO

the error values is not part of the interface to the user,
so they should never be printed in LOG_INFO or LOG_USER.

Printing them in LOG_DEBUG() rarely makes much sense but
is OK.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agotcl/interface/flashlink.cfg: Fix broken ST URL
Tormod Volden [Sun, 19 Dec 2010 22:39:05 +0000 (23:39 +0100)]
tcl/interface/flashlink.cfg: Fix broken ST URL

8 years agotcl/board: Clean up STM32 EVAL boards configurations
Tormod Volden [Sun, 19 Dec 2010 22:39:04 +0000 (23:39 +0100)]
tcl/board: Clean up STM32 EVAL boards configurations

Make consistent use of hex memory size for flashing.

Delete stm32f10x_128k_eval.cfg. It has no product reference
nor any settings in it.

8 years agotcl/board: Fix ST URLs in stm32* eval board configuration files
Tormod Volden [Sun, 19 Dec 2010 22:39:03 +0000 (23:39 +0100)]
tcl/board: Fix ST URLs in stm32* eval board configuration files

ST recently rewamped (screwed up) their web site and broke all links.
Also match the chip names with those on the web site product
descriptions.

8 years agoupdate IXP42x target / XBA board config
Michael Schwingen [Sun, 19 Dec 2010 15:17:46 +0000 (16:17 +0100)]
update IXP42x target / XBA board config

8 years agoAdd support for Hilscher netX controllers
Michael Trensch [Thu, 16 Dec 2010 14:33:16 +0000 (15:33 +0100)]
Add support for Hilscher netX controllers

8 years agoscript: support only Tcl comments
Øyvind Harboe [Sat, 18 Dec 2010 09:16:26 +0000 (10:16 +0100)]
script: support only Tcl comments

Only Tcl comments are now supported. For classic style
commands comments were supported at the end of the line.

Move in the direction of letting the script language
decide syntax, rather than have special rules for some
commands.

Before this patch goes in, the scripts should be updated
to use ;# instead of # for end of line comments.

> mdw 0 1 2
mdw ['phys'] address [count]
  zy1000.cpu mdw address [count]
Command handler execution failed
in procedure 'mdw'
> mdw 0 1 #2
mdw ['phys'] address [count]
  zy1000.cpu mdw address [count]
Command handler execution failed
in procedure 'mdw'
> mdw 0 1 ;#2
0x00000000: ffffffff
> mdw 0 1
0x00000000: ffffffff
> mdw 0
0x00000000: ffffffff

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoTCL: fix non TCL comments
Antonio Borneo [Sat, 18 Dec 2010 17:22:53 +0000 (01:22 +0800)]
TCL: fix non TCL comments

End of line comments fixed with ';' before '#'.
Added few additional 'space' to keep indentation in
multi-line comments.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoopenocd doc: update the comments about Jim Tcl a bit
Øyvind Harboe [Thu, 16 Dec 2010 08:12:22 +0000 (09:12 +0100)]
openocd doc: update the comments about Jim Tcl a bit

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoFix for compilation failure amt_jtagaccel.c
John Devereux [Tue, 14 Dec 2010 12:17:01 +0000 (12:17 +0000)]
Fix for compilation failure amt_jtagaccel.c

Hi,

I think there are errors in amt_jtagaccel.c

I attach a small patch that I needed to make it compile.

8 years agoFix for segfault in handle_nand_dump_command.
Paul Richards [Wed, 15 Dec 2010 12:42:03 +0000 (21:42 +0900)]
Fix for segfault in handle_nand_dump_command.

8 years agostm32: fix unprotect
Øyvind Harboe [Tue, 14 Dec 2010 08:26:08 +0000 (09:26 +0100)]
stm32: fix unprotect

the unprotect fn in stm32 needs to unprotect more sectors
than was requested aligned to some boundary.

Print warning when this happens.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoflash: clarify protect documentation
Øyvind Harboe [Tue, 14 Dec 2010 08:29:26 +0000 (09:29 +0100)]
flash: clarify protect documentation

some chips unprotect more than the range asked for. The
protect fn, must unprotect/protect minimally the range given.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agocontrib: add source to the cfi flash loaders
Spencer Oliver [Fri, 10 Dec 2010 19:37:39 +0000 (19:37 +0000)]
contrib: add source to the cfi flash loaders

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocontrib: make sure loaders use correct arch
Spencer Oliver [Thu, 9 Dec 2010 16:42:04 +0000 (16:42 +0000)]
contrib: make sure loaders use correct arch

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agostm32: add STM32E-EVAL external memory config script
Spencer Oliver [Wed, 8 Dec 2010 17:15:42 +0000 (17:15 +0000)]
stm32: add STM32E-EVAL external memory config script

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocfi: disable buffer writes for M29W128G
Spencer Oliver [Wed, 8 Dec 2010 17:11:07 +0000 (17:11 +0000)]
cfi: disable buffer writes for M29W128G

For some reason buffer writes for the M29W128G do not work reliably,
so disable them.

See:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=504a3e72208fc6a65924426ff5693982590bccdc

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocfi: allow optional buffer write support
Spencer Oliver [Wed, 8 Dec 2010 17:07:08 +0000 (17:07 +0000)]
cfi: allow optional buffer write support

Some flash's do not support buffer writes, so we now check
they are supported before trying to use them.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocfi: calculate correct timeouts
Spencer Oliver [Wed, 8 Dec 2010 17:04:23 +0000 (17:04 +0000)]
cfi: calculate correct timeouts

The existing code used incorrect timeout values for the various cfi
operations. We now calculate the timeouts and convert to
msecs if necessary.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocfi: prefix string hex output
Spencer Oliver [Wed, 8 Dec 2010 16:57:44 +0000 (16:57 +0000)]
cfi: prefix string hex output

Add hex prefix so we know output is not decimal.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocfi: add time format to cfi query output
Spencer Oliver [Wed, 8 Dec 2010 10:57:36 +0000 (10:57 +0000)]
cfi: add time format to cfi query output

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocfi: whitespace and long line cleanup
Spencer Oliver [Wed, 8 Dec 2010 10:14:15 +0000 (10:14 +0000)]
cfi: whitespace and long line cleanup

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agoFix for segmentation fault from freed memory access in jtag_unregister_event_callback()
Paul Richards [Wed, 8 Dec 2010 06:48:55 +0000 (15:48 +0900)]
Fix for segmentation fault from freed memory access in jtag_unregister_event_callback()

8 years agoremove srst_pulls_trst from LPC2xxx target scripts
Freddie Chopin [Sat, 4 Dec 2010 14:45:40 +0000 (15:45 +0100)]
remove srst_pulls_trst from LPC2xxx target scripts

LPC2xxx do not require reset_config srst_pulls_trst. This can cause various "strange" problems when flashing the chip, because "reset halt" actually allows the chip to run for some short period of time and execute some code.

Signed-off-by: Freddie Chopin <freddie_chopin@op.pl>
8 years agobuild: fix build from previous commit
Spencer Oliver [Wed, 8 Dec 2010 19:54:10 +0000 (19:54 +0000)]
build: fix build from previous commit

commit 740b9e25b410c164e661d0334a9ea4168406726b broke the drivers
for ftdi and parport due to retval already being defined.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agojtag: getting the JTAG speed can fail
Øyvind Harboe [Mon, 6 Dec 2010 08:21:23 +0000 (09:21 +0100)]
jtag: getting the JTAG speed can fail

If the JTAG speed has not been set, then it has no defined
value, add code to propagate the error.

No change to actual behavior as no new failure paths have
been introduced. This is a no-op patch to make subsequent patches
smaller.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agosvf: various improvements
Andrew Leech [Mon, 6 Dec 2010 21:05:56 +0000 (08:05 +1100)]
svf: various improvements

* added support for targeting particular tap
* improved file reading
* improved command line parsing
* added progress meter
* more readable time measurement output

8 years agolpc2478 target config: CCLK as (mandatory) parameter
Rolf Meeser [Fri, 3 Dec 2010 13:10:40 +0000 (14:10 +0100)]
lpc2478 target config: CCLK as (mandatory) parameter

8 years agoxscale: trace buffer remains enabled until explicitly disabled
Mike Dunn [Thu, 2 Dec 2010 19:08:28 +0000 (11:08 -0800)]
xscale: trace buffer remains enabled until explicitly disabled

Hi everyone,

Since a call went out for patches... been sitting on this for months.  For some
reason, the xscale trace buffer is automatically disabled as soon as a break
occurs and the trace data is collected.  This patch was a result of the
frustration of always re-enabling it, or else hitting a breakpoint and checking
the trace data, only to discover that I forgot to re-enable it before resuming.
Don't see why it should work this way.  There is no run-time penalty, AFAIK.

Along the way, I also cleaned up a little by removing the ugly practice of
recording wrap mode by setting the fill count variable to "-1", replacing it
with an enum that records the trace mode.

I've been using this for months.  Comments, criticisms gratefully received.

Mike

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
8 years agoAdd board config for Embedded Artists LPC2478-32
Rolf Meeser [Fri, 3 Dec 2010 13:03:28 +0000 (14:03 +0100)]
Add board config for Embedded Artists LPC2478-32

8 years agoFix flash name in Hitex LPC2929 board config
Rolf Meeser [Fri, 3 Dec 2010 12:54:47 +0000 (13:54 +0100)]
Fix flash name in Hitex LPC2929 board config

8 years agoFix sector layout for 504-KiB LPC2000 devices
Rolf Meeser [Fri, 3 Dec 2010 13:06:11 +0000 (14:06 +0100)]
Fix sector layout for 504-KiB LPC2000 devices

8 years agostm32: set default soft reset config
Spencer Oliver [Thu, 2 Dec 2010 13:12:48 +0000 (13:12 +0000)]
stm32: set default soft reset config

If no srst is configured then default to using sysresetreq to
reset the target.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agoluminary: remove unused config cmds.
Spencer Oliver [Thu, 2 Dec 2010 13:11:08 +0000 (13:11 +0000)]
luminary: remove unused config cmds.

Due to commit e40aee2954d2beabe1d8c530d9ff1e564fb01f48 we now honour the
targets 'reset_config' setting. Previously we ignored the srst setting
for luminary targets.

Luminary targets have never supported using srst to reset into debug mode
so remove the option from the target configs files.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agocortex_m3: change cortec_m3 reset_config behaviour
Spencer Oliver [Thu, 2 Dec 2010 12:58:50 +0000 (12:58 +0000)]
cortex_m3: change cortec_m3 reset_config behaviour

Currently the cmd 'cortex_m3 reset_config' will overide the default
target's 'reset_config'.
Chnage the behaviour to use the target 'reset_config' if configured and
fallback if not.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agoconfig: fix luminary jtag config
Spencer Oliver [Thu, 2 Dec 2010 22:01:44 +0000 (22:01 +0000)]
config: fix luminary jtag config

When this config was updated in commit e3773e3e3d1f1ee0dbb0b69e8babe8419784d1c1
the old jtag declaration was not removed.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agorename some target scripts to be consistent with the rest
Freddie Chopin [Wed, 1 Dec 2010 21:55:56 +0000 (22:55 +0100)]
rename some target scripts to be consistent with the rest

Rename Atmel target scripts which had wrong name ("at91" missing for ARM7 AT91SAM7..., "at" missing for AVR ATmega...)

Signed-off-by: Freddie Chopin <freddie_chopin@op.pl>
8 years agoprofile: use 100Hz as a default sampling frequency
Øyvind Harboe [Wed, 1 Dec 2010 14:28:56 +0000 (15:28 +0100)]
profile: use 100Hz as a default sampling frequency

it's a lie that is somewhere in the vicinity of the
truth. Certainly 64MHz confuses gprof and produces
zero output and no error messages.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agolpc2900.c: Improve debug output for device probing
Rolf Meeser [Wed, 1 Dec 2010 07:28:43 +0000 (08:28 +0100)]
lpc2900.c: Improve debug output for device probing

8 years agolpc2900.c: Add support for new device LPC2926
Rolf Meeser [Wed, 1 Dec 2010 07:22:29 +0000 (08:22 +0100)]
lpc2900.c: Add support for new device LPC2926

8 years agoLPC2900: Avoid false positive reprobing if first probing fails
Rolf Meeser [Sat, 27 Nov 2010 22:09:59 +0000 (23:09 +0100)]
LPC2900: Avoid false positive reprobing if first probing fails

8 years agoSome cosmetic fixes to the Lisa/L layout support functions.
Piotr Esden-Tempski [Mon, 29 Nov 2010 20:58:30 +0000 (12:58 -0800)]
Some cosmetic fixes to the Lisa/L layout support functions.

8 years agoAdded support for the blinking leds on Floss-JTAG v0.3 and newer.
Piotr Esden-Tempski [Mon, 29 Nov 2010 20:56:21 +0000 (12:56 -0800)]
Added support for the blinking leds on Floss-JTAG v0.3 and newer.

8 years agoUpdated Floss-JTAG config file to support v0.3 and newer. Also added noeeprom version...
Piotr Esden-Tempski [Mon, 29 Nov 2010 20:35:39 +0000 (12:35 -0800)]
Updated Floss-JTAG config file to support v0.3 and newer. Also added noeeprom version of the config file for older versions of Floss-JTAG.

8 years agobuild: fix make install with jimtcl
Spencer Oliver [Fri, 26 Nov 2010 14:43:44 +0000 (14:43 +0000)]
build: fix make install with jimtcl

Update subproject jimtcl to fix issue with make install.
see jimtcl commit 373b721510fd2d0754a41cc70a3b7cfd02e929bd

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: correct configure help message
Spencer Oliver [Fri, 26 Nov 2010 13:35:41 +0000 (13:35 +0000)]
build: correct configure help message

As we default to building jimtcl the help text should show that.
No change in functionality or configure args required.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agoFLASH/NOR: Rename spearsmi.c to stmsmi.c
Antonio Borneo [Mon, 22 Nov 2010 04:25:09 +0000 (12:25 +0800)]
FLASH/NOR: Rename spearsmi.c to stmsmi.c

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: rename from spearsmi to stmsmi
Antonio Borneo [Mon, 22 Nov 2010 04:21:31 +0000 (12:21 +0800)]
FLASH/NOR: rename from spearsmi to stmsmi

STMicroelectronics controller SMI is not SPEAr specific.
Rename it and change name to every symbol in the code.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoSTR750: Add SMI interface support
Antonio Borneo [Wed, 17 Nov 2010 03:28:46 +0000 (11:28 +0800)]
STR750: Add SMI interface support

Modified spearsmi driver to include support for STR75x
Added missing initialization in tcl file for STR750

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNOR/SPEARSMI: fix segfault
Antonio Borneo [Thu, 18 Nov 2010 07:01:03 +0000 (15:01 +0800)]
NOR/SPEARSMI: fix segfault

If flash chip is not listed in the table, or if no flash is
connected, pointer must be properly initialized.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoDocumentation: fix typo
Antonio Borneo [Mon, 22 Nov 2010 11:32:57 +0000 (19:32 +0800)]
Documentation: fix typo

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoflash: iterating over an address range now handles multiple banks
Øyvind Harboe [Mon, 22 Nov 2010 10:16:40 +0000 (11:16 +0100)]
flash: iterating over an address range now handles multiple banks

e.g. flash erase_address now works across an address
range that spans multiple flash chips.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agofastload: fix error handling upon running out of memory
Øyvind Harboe [Mon, 22 Nov 2010 08:15:47 +0000 (09:15 +0100)]
fastload: fix error handling upon running out of memory

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agobuild: remove AC_CONFIG_AUX_DIR macro
Spencer Oliver [Fri, 19 Nov 2010 11:53:17 +0000 (11:53 +0000)]
build: remove AC_CONFIG_AUX_DIR macro

This was used during testing and should have been removed.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: disable jimtcl lineedit
Spencer Oliver [Fri, 19 Nov 2010 11:24:11 +0000 (11:24 +0000)]
build: disable jimtcl lineedit

This is a recent jimtcl feature but it currently breaks mingw
builds as this system does not have termios.h etc.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: fix subconfigure parameter issue
Spencer Oliver [Fri, 19 Nov 2010 09:57:37 +0000 (09:57 +0000)]
build: fix subconfigure parameter issue

When passing CFLAGS for example through to the jimtcl subconfigure the
quotes were not being preserved.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: update bootstrap comments
Spencer Oliver [Fri, 19 Nov 2010 09:08:09 +0000 (09:08 +0000)]
build: update bootstrap comments

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: prepend --with-jim-ext=nvp to jimtcl configure
Spencer Oliver [Fri, 19 Nov 2010 09:07:43 +0000 (09:07 +0000)]
build: prepend --with-jim-ext=nvp to jimtcl configure

This allows us to add options to jimtcl configure.
The default autoconf AC_CONFIG_SUBDIRS does not currently support this.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: add autobuild jimtcl to configure scripts
Spencer Oliver [Wed, 17 Nov 2010 10:26:21 +0000 (10:26 +0000)]
build: add autobuild jimtcl to configure scripts

Rather than having to configure/build jimtcl openocd
will do this as part of its own build.

To use an external jimtcl lib specify disable-internal-jimtcl
to the configure step.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agobuild: add common.mk
Spencer Oliver [Fri, 12 Nov 2010 11:41:55 +0000 (11:41 +0000)]
build: add common.mk

Rather than specifying common makefile variables move
them all to a common.mk.

Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>
8 years agoFLASH/NOR: Remove useless file tms470.h
Antonio Borneo [Wed, 17 Nov 2010 13:28:34 +0000 (21:28 +0800)]
FLASH/NOR: Remove useless file tms470.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file str9xpec.h
Antonio Borneo [Wed, 17 Nov 2010 13:25:57 +0000 (21:25 +0800)]
FLASH/NOR: Remove useless file str9xpec.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file str9x.h
Antonio Borneo [Wed, 17 Nov 2010 13:23:04 +0000 (21:23 +0800)]
FLASH/NOR: Remove useless file str9x.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file str7x.h
Antonio Borneo [Wed, 17 Nov 2010 13:20:02 +0000 (21:20 +0800)]
FLASH/NOR: Remove useless file str7x.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file stm32x.h
Antonio Borneo [Wed, 17 Nov 2010 13:16:23 +0000 (21:16 +0800)]
FLASH/NOR: Remove useless file stm32x.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file stellaris.h
Antonio Borneo [Wed, 17 Nov 2010 13:12:37 +0000 (21:12 +0800)]
FLASH/NOR: Remove useless file stellaris.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file pic32mx.h
Antonio Borneo [Wed, 17 Nov 2010 13:04:37 +0000 (21:04 +0800)]
FLASH/NOR: Remove useless file pic32mx.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file lpc288x.h
Antonio Borneo [Wed, 17 Nov 2010 13:00:25 +0000 (21:00 +0800)]
FLASH/NOR: Remove useless file lpc288x.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file lpc2000.h
Antonio Borneo [Wed, 17 Nov 2010 12:55:40 +0000 (20:55 +0800)]
FLASH/NOR: Remove useless file lpc2000.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file avrf.h
Antonio Borneo [Wed, 17 Nov 2010 10:01:07 +0000 (18:01 +0800)]
FLASH/NOR: Remove useless file avrf.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoflash: fix bug with multiple back-to-back flash chips
Øyvind Harboe [Mon, 15 Nov 2010 13:43:16 +0000 (14:43 +0100)]
flash: fix bug with multiple back-to-back flash chips

flash programming via flash write_image or gdb load would
produce a bogus error message that the flash chip was to
small.

The solution is to limit the current flash programming
run to the current chip.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
8 years agoFLASH/NOR: Remove useless file at91sam7.h
Antonio Borneo [Wed, 17 Nov 2010 02:53:30 +0000 (10:53 +0800)]
FLASH/NOR: Remove useless file at91sam7.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file at91sam3.h
Antonio Borneo [Wed, 17 Nov 2010 02:25:55 +0000 (10:25 +0800)]
FLASH/NOR: Remove useless file at91sam3.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoFLASH/NOR: Remove useless file spearsmi.h
Antonio Borneo [Wed, 17 Nov 2010 00:21:22 +0000 (08:21 +0800)]
FLASH/NOR: Remove useless file spearsmi.h

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNOR/SPEARSMI: Add comments about SPI
Antonio Borneo [Wed, 17 Nov 2010 00:12:45 +0000 (08:12 +0800)]
NOR/SPEARSMI: Add comments about SPI

SMI interface hides the real SPI bus between SPEAr and
external flash.
Added comments to highlight the SPI operation, to help a
future rework in SPI generic and SPEAr specific drivers.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoTCL/SPEAr: Added Serial flash in board file
Antonio Borneo [Thu, 11 Nov 2010 06:16:52 +0000 (14:16 +0800)]
TCL/SPEAr: Added Serial flash in board file

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
8 years agoNOR/SPEAr: Add support for Serial NOR
Antonio Borneo [Thu, 11 Nov 2010 06:12:31 +0000 (14:12 +0800)]
NOR/SPEAr: Add support for Serial NOR

Add support and documentation for STMicroelectronics
SPEAr Serial Memory Interface (SMI).
Code tested on SPEAr3xx only.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>