Commit Graph

208 Commits

Author SHA1 Message Date
David Brownell
7252a72465 Houston, we have Mirror! 2009-10-07 19:11:37 -07:00
dbrownell
03c9e48f88 Change most in-tree references from SVN to GIT.
Also, talk about "mainline" not "trunk".

The release.txt and release.sh files need more updates.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2825 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-10-08 00:13:50 +00:00
dbrownell
f8c8d8bc72 Remove pointless "target library" chapter.
It had a very little bit of content; move that to the more extensive
chapter on config file guidelines, and give more current "ls" output
to show the available library code.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2820 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-10-07 16:15:21 +00:00
dbrownell
f2dc1eeef1 Note bug in handling of variables through command line parameters.
git-svn-id: svn://svn.berlios.de/openocd/trunk@2819 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-10-07 15:56:11 +00:00
dbrownell
b83d79a42f Updates for "reset_config":
- revert to previous default: don't talk JTAG during SRST
 - add "srst_nogates" flag, the converse of "srst_gates_jtag"
 - with no args, display the current configuration

And update the User's Guide text with bullet lists to be a bit more clear.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2818 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-10-07 15:31:33 +00:00
dbrownell
7c7467b34f Add a new JTAG "setup" event; use for better DaVinci ICEpick support.
The model is that this fires after scanchain verification, when it's
safe to call "jtag tapenable $TAPNAME".  So it will fire as part of
non-error paths of "init" and "reset" command processing.  However it
will *NOT* trigger during "jtag_reset" processing, which skips all
scan chain verification, or after verification errors.

ALSO:
 - switch DaVinci chips to use this new mechanism
 - log TAP activation/deactivation, since their IDCODEs aren't verified
 - unify "enum jtag_event" scripted event notifications
 - remove duplicative JTAG_TAP_EVENT_POST_RESET


git-svn-id: svn://svn.berlios.de/openocd/trunk@2800 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-10-05 08:20:28 +00:00
dbrownell
1033633321 Minor ETB and ETM bugfixes and doc updates
- ETB
    * report _actual_ hardware status, not just expected status
    * add a missing diagnostic on a potential ETB setup error
    * prefix any diagnostics with "ETB"
 - ETM
    * make "etm status" show ETM hardware status too, instead of
      just traceport status (which previously was fake, sigh)
 - Docs
    * flesh out "etm tracemode" docs a bit
    * clarify "etm status" ... previously it was traceport status
    * explain "etm trigger_percent" as a *traceport* option

ETM+ETB tracing still isn't behaving, but now I can see that part of 
the reason is that the ETB turns itself off almost immediately after
being enabled, and before collecting any data.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2790 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-10-02 09:19:03 +00:00
dbrownell
6d4cdddbe2 ARM11 command handling fixes
- Commands were supposed to have been "arm11 memwrite ..."
   not "memwrite ..."
 - Get rid of obfuscatory macros
 - Re-alphabetize
 - Add docs for "arm11 vcr"


git-svn-id: svn://svn.berlios.de/openocd/trunk@2776 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-29 18:30:06 +00:00
dbrownell
4297209ac9 Make "-expected-id 0" suppress warnings; not unlike it used to do.
git-svn-id: svn://svn.berlios.de/openocd/trunk@2775 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-29 18:26:18 +00:00
dbrownell
bde4a40422 Doc updates: add section on target software changes, minor fixes
git-svn-id: svn://svn.berlios.de/openocd/trunk@2774 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-29 18:20:30 +00:00
dbrownell
2e210ee48f Streamline Capture-IR handling and integrity test.
Change the handling of the "-ircapture" and "-irmask" parameters
to be slightly more sensible, given that the JTAG spec describes
what is required, and that we already require that conformance in
one place.  IR scan returns some bitstring with LSBs "01".

 - First, provide and use default values that satisfy the IEEE spec.
   Existing TAP configs will override the defaults, but those parms
   are no longer required.

 - Second, warn if any TAP gets set up to violate the JTAG spec.
   It's likely a bug, but maybe not; else this should be an error.
   Improve the related diagnostics to say which TAP is affected.

And associated minor fixes/cleanups to comments and diagnostics.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2758 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-26 19:08:34 +00:00
dbrownell
22045fa6f2 When setting up an ETM, cache its ETM_CONFIG register. Then
only expose the registers which are actually present.  They
could be missing for two basic reasons:

 - This version might not support them at all; e.g. ETMv1.1
   doesn't have some control/status registers.  (My sample of
   ARM9 boards shows all with ETMv1.3 support, FWIW.)

 - The configuration on this chip may not populate as many
   registers as possible; e.g. only two data value comparators
   instead of eight.

Includes a bugfix in the "etm info" command:  only one of the
two registers is missing on older silicon, so show the first
one before bailing.

Update ETM usage docs to explain that those registers need to be
written to configure what is traced, and that some ETM configs
are not yet handled.  Also, give some examples of the kinds of
constrained trace which could be arranged.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2752 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-23 21:52:40 +00:00
dbrownell
50b94628ae Make it easier to erase or protect through to the end
of a (NOR) flash chip: allow passing "last" as an alias
for the number of the last sector.

Improve several aspects of error checking while we're at it.

From: Johnny Halfmoon <jhalfmoon@milksnot.com>


git-svn-id: svn://svn.berlios.de/openocd/trunk@2746 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-22 05:39:06 +00:00
dbrownell
6cba486356 Update presentation of TAP events and tap enable/disable.
Highlight that the "post-reset" event kicks in before the
scan chain is validated, which limits what can be done
in a post-reset handler.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2745 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-21 21:35:56 +00:00
dbrownell
b11d79110e Remove annoying end-of-line whitespace from doc/* files.
git-svn-id: svn://svn.berlios.de/openocd/trunk@2744 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-21 18:52:45 +00:00
dbrownell
24df719b09 Update the User's Guide to cover the scan chain verification step
done on exit from the config stage, how JTAG clocking issues can
trigger errors there, and how to avoid such problems.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2737 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-20 21:17:08 +00:00
dbrownell
74ae645623 Minor tweaks to description of JTAG adapter/dongle issues.
git-svn-id: svn://svn.berlios.de/openocd/trunk@2729 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-19 06:42:50 +00:00
dbrownell
9536577c02 Minor fixes to NAND code and docs
Erase logic:
 - command invocation
    + treat "nand erase N" (no offset/length) as "erase whole chip N"
    + catch a few more bogus parameter cases, like length == 0 (sigh)
 - nand_erase() should be static
 - on error
    + say which block failed, and if it was a bad block
    + don't give up after the first error; try to erase the rest
 - on success, say which nand device was erased (name isn't unique)

Device list ("nand list"):
 - say how many blocks there are
 - split summary into two lines
 - give example in the docs

Doc tweaks:
 - Use @option{...} for DaVinci's supported hardware ECC options

For the record, I've observed that _sometimes_ erasing bad blocks causes
failure reports, and that manufacturer bad block markers aren't always
erasable (even when erasing their blocks doesn't trigger an error report).


git-svn-id: svn://svn.berlios.de/openocd/trunk@2724 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-17 18:56:17 +00:00
oharboe
016e7ebbfa srst_gates_jtag option. at91sam9260 needs retesting, and possibly srst_gates_jtag added to reset_config. Could i.MX27 be a case where srst does not pull trst, but really srst gates jtag clock?
git-svn-id: svn://svn.berlios.de/openocd/trunk@2720 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-17 11:23:41 +00:00
dbrownell
cb7ad25c04 The "arm9tdmi.c" file is more of a generic ARM9 support file:
- update comments to say so.
 - update docs to clarify that the "arm9tdmi" command prefix
   is a misnomer.
 - bugfix some messages that wrongly assume only ARM9TDMI
   based processors use this code.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2719 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-17 08:02:43 +00:00
dbrownell
e18bd3b55e Doc update: mention how ARM's WFI instruction affects
JTAG clocking by gating the core clock, and workarounds.
Most details are with the "halt" command, which is one
of the first places this issue will be noticed.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2718 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-17 07:56:24 +00:00
oharboe
9542318312 Rolf Meeser <rolfm_9dq@yahoo.de> adds flash support for NXP's LPC2900 family (ARM968E).
git-svn-id: svn://svn.berlios.de/openocd/trunk@2715 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-16 12:38:26 +00:00
oharboe
a17eb667a3 Dirk Behme <dirk.behme@googlemail.com> document post TAP reset event
git-svn-id: svn://svn.berlios.de/openocd/trunk@2700 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-12 13:05:20 +00:00
oharboe
8b2b0071a9 David Brownell <david-b@pacbell.net>
Fix docs on ARM11 MCR and MRC coprocessor commands:
correct read-vs-write; and describe the params.

(ARM920 and ARM926 have cp15-specific commands; this
approach is more generic.  MCR2, MRC2, MCRR, MCRR2,
MRRC, and MRRC2 instructions could also get exposed.)

git-svn-id: svn://svn.berlios.de/openocd/trunk@2679 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-09 06:27:47 +00:00
oharboe
5dae4753ff David Brownell <david-b@pacbell.net>
Provide an "armv7a disassemble" command.  Current omissions include
VFP (except as coprocessor instructions), Neon, and various Thumb2
opcodes that are not available in ARMv7-M processors.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2676 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-09-08 06:18:45 +00:00
oharboe
ab30d5203c David Brownell <david-b@pacbell.net> Minor doc updates:
- Itemize the list of private customization examples
  for openocd.cfg

 - Add "override defaults" as a customization, specifically
  for the work area (back it up or relocate it)

 - Highlight some work area location issues

git-svn-id: svn://svn.berlios.de/openocd/trunk@2651 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-30 17:32:56 +00:00
oharboe
d879faa3cb David Brownell <david-b@pacbell.net> start phasing out integers as target IDs
git-svn-id: svn://svn.berlios.de/openocd/trunk@2650 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-30 17:30:14 +00:00
oharboe
bc075606b7 David Brownell <david-b@pacbell.net> Tweak disassembly commands:
For ARMv4/ARMv5:
  - better command parameter error checking
  - don't require an instruction count; default to one
  - recognize thumb function addresses
  - make function static
  - shorten some too-long lines
 For Cortex-M3:
  - don't require an instruction count; default to one

With the relevant doc updates.
---
Nyet done:  invoke the thumb2 disassembler on v4/v5,
to better handle branch instructions.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2624 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-25 20:02:19 +00:00
oharboe
0c41395fc3 Michael Schwingen <rincewind@discworld.dascon.de> fix previous doc patch
git-svn-id: svn://svn.berlios.de/openocd/trunk@2619 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-25 13:00:45 +00:00
oharboe
fd4c0f33b1 Michael Schwingen <rincewind@discworld.dascon.de> The attached patch adds a "xscale vector_table" command that allows to set
the values that are written in the mini-IC (plus documentation updates that
describe why this is needed).

git-svn-id: svn://svn.berlios.de/openocd/trunk@2613 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-25 07:09:48 +00:00
ntfreak
a6f9c5a796 - add cfg file for Amontec JTAGKey2 jtag interface
git-svn-id: svn://svn.berlios.de/openocd/trunk@2592 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-18 16:46:48 +00:00
oharboe
ed22097a55 David Brownell <david-b@pacbell.net> Add "cortex_m3 vector_catch" command and docs. One minor
issue with this is that the core debug support uses this
mechanism, then trashes its state over reset.  Users can
Work around that (for now) by re-assigning the desired
config after reset.

Also fixes "target halted due to target-not-halted" goof.
When we can't describe the reason using OpenOCD's limited
vocabulary, say "reason undefined" instead of saying it's
not halted.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2588 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-18 10:25:28 +00:00
ntfreak
59b295dbbe Audrius Urmanavičius [didele.deze@gmail.com]:
Add flash programming support for NXP LPC1700 cortex_m3 based family


git-svn-id: svn://svn.berlios.de/openocd/trunk@2579 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-13 13:54:53 +00:00
ntfreak
732df6fea0 David Brownell <david-b@pacbell.net>:
Better explanation for the TAP "-ircapture" parameter.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2577 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-08-07 09:29:41 +00:00
zwelch
309870e414 David Brownell <david-b@pacbell.net>:
Initial support for disassembling Thumb2 code.  This works only for
Cortex-M3 cores so far.  Eventually other cores will also need Thumb2
support ... but they don't yet support any kind of disassembly.

 - Update the 16-bit Thumb decoder:
 
     * Understand CPS, REV*, SETEND, {U,S}XT{B,H} opcodes added
       by ARMv6.  (It already seems to treat CPY as MOV.)

     * Understand CB, CBNZ, WFI, IT, and other opcodes added by
       in Thumb2.

 - A new Thumb2 instruction decode routine is provided.
 
     * This has a different signature:  pass the target, not the
       instruction, so it can fetch a second halfword when needed.  
       The instruction size is likewise returned to the caller.

     * 32-bit instructions are recognized but not yet decoded.
   
 - Start using the current "UAL" syntax in some cases.  "SWI" is
   renamed as "SVC"; "LDMIA" as "LDM"; "STMIA" as "STM".

 - Define a new "cortex_m3 disassemble addr count" command to give
   access to this disassembly.

Sanity checked against "objdump -d" output; a bunch of the new
instructions checked out fine.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2530 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-07-15 23:39:37 +00:00
ntfreak
1df358855a - fix small typo in documentation
git-svn-id: svn://svn.berlios.de/openocd/trunk@2525 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-07-14 11:57:59 +00:00
oharboe
6996e628f8 David Brownell <david-b@pacbell.net> Mention how parallel clock voting implementations of RTCK work,
and reference TI's free VHDL code.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2508 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-07-12 14:08:16 +00:00
oharboe
42115c0997 David Brownell <david-b@pacbell.net> Update docs to say that "arm7_9 dbgrq enable" is the default
on ARM9 cores, and update the DaVinci config files so they
no longer explicitly specify it.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2484 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-07-06 21:16:11 +00:00
oharboe
35000e10d0 David Brownell <david-b@pacbell.net> Fix two texinfo formatting bugs. The first was visible by
reading the output, and both were reported in openocd.log
after making the PDF.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2449 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-07-02 07:12:59 +00:00
zwelch
92ddc0266b Provide some useful information in README file, rather than punting.
Add some text to introduce the project to new users.

Move packaging, configuration, and compilation of OpenOCD out of
the User's Guide and into README, where it can be used by users
before configuring and compiling the documentation.

Improve notes about required Subversion repository build steps.
Add reference to the standard GNU INSTALL file.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2436 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-30 21:45:26 +00:00
zwelch
f130f95d45 Marcel Jost <marcel.jost@bfh.ch>:
This patch adds support for the Luminary Micro LM3S9B90 target and
LM3S9B92 Evaluation Kit.  These kits include a new ft2232 adapter, the
Luminary In-Circuit Debug Interface (ICDI) Board, so this is added as a
new ft2232 layout called "luminary_icdi".


git-svn-id: svn://svn.berlios.de/openocd/trunk@2429 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-30 09:09:30 +00:00
zwelch
0894ae214a David Brownell <david-b@pacbell.net>:
Add "jtag names" command, mirroring "target names" but returning
TAP names instead of target names.  This starts letting TAPs be
manipulated in scripts ... much like what works now for targets.

It's a bit limited just yet, since "jtag cget $TAPNAME" doesn't
expose all TAP attributes.  "$TARGETNAME cget" is more functional.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2428 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-30 09:03:59 +00:00
zwelch
f0fd28a66c David Brownell <david-b@pacbell.net>:
Warn when people (or scripts) use numeric identifiers for TAPs,
instead of dotted.name values.  We want this usage to go away,
so that for example adding more TAPs doesn't cause config scripts
to break because some sequence number changed.

It's been deprecated since late 2008, but putting a warning on
this should help us remove it (say, in June 2010) by helping to
phase out old (ab)usage in config scripts.

Other than in various config files, the only code expecting such
a number was the almost unused str9xpec driver.  This code was
changed to use the TAP it was passed, instead of making its own
dubious lookup and ignoring that TAP.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2415 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-29 20:03:59 +00:00
zwelch
54ffd82a1a David Brownell <david-b@pacbell.net>:
Minor fixup to the User's Guide, primarily related to the
handful of commands defined in "startup.tcl"; "help" was
not previously documented.

Also, be more consistent about "Config Command" definitions
(and to be explicit about that doc convention).


git-svn-id: svn://svn.berlios.de/openocd/trunk@2414 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-29 20:03:52 +00:00
oharboe
445fef39fb David Brownell <david-b@pacbell.net> various missing commands
git-svn-id: svn://svn.berlios.de/openocd/trunk@2412 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-28 18:46:51 +00:00
oharboe
37b15fb2c4 David Brownell <david-b@pacbell.net> Add a short chapter on boundary scan support, which currently
just documents the SVF and XSVF commands.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2404 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-26 07:30:21 +00:00
oharboe
5505b8fa63 David Brownell <david-b@pacbell.net> Fix formatting bug in at91sam7 doc added with the at91sam3 support;
and some formatting issues with sam7 and stm32 keyword params.

Tweak at91sam3 docs.  Remove ninth nibble from flash bank addresses,
clarify "at91sam3 show" variants and that the flash bank layout is
not needed as a parameter (unlike with sam7); formatting fixes.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2400 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-24 16:56:11 +00:00
duane
0ace4d24db Add support for ATMEL AT91SAM3U - CortexM3 Family
git-svn-id: svn://svn.berlios.de/openocd/trunk@2383 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-24 02:01:14 +00:00
zwelch
5a6f218a9c David Brownell <david-b@pacbell.net>:
Move the short chapter about JIM-Tcl earlier, so that we
can reasonably assume it's been introduced before we start
presenting things that presume such an introduction.
Plus a few minor typo-level fixes.


git-svn-id: svn://svn.berlios.de/openocd/trunk@2355 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-22 22:37:04 +00:00
zwelch
1017e62c97 David Brownell <david-b@pacbell.net>:
This should be my last significant update of the User's Guide for
this release.  Mostly it's a rework of the config file chapter's
presentation of board and target config files.

 - Give the new path for scripts!
 - Move board-config material out of the target-config section
 - Add more board-config info, notably for reset-init events
 - Link out of the board-config section to NAND, NOR, and Reset chapters
 - Emphasize target input vs. output naming conventions
 - Other textual improvements

Plus some other updates, like adding my copyright (now that I've
basically rewritten much of this).


git-svn-id: svn://svn.berlios.de/openocd/trunk@2354 b42882b7-edfa-0310-969c-e2dbd0fdcd60
2009-06-22 22:36:53 +00:00