Commit Graph

3011 Commits (8cc8c0544f3f24772d6644df16d5a70d4ffe8b4a)

Author SHA1 Message Date
Zachary T Welch 7b2d8d93e6 Improve lpc2900.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 0004691e91 Improve lpc288x.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 7f6ad49d12 Improve lpc2000.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 680e22c4d7 Improve cfi.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 7b3d54a127 Improve avrf.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 266c423bbd Improve orion_nand.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 7b49739790 Improve davinci_nand.c command argument parsing. 2009-11-05 18:19:18 -08:00
Zachary T Welch 75b601b1f3 Improve at91sam7.c command argument parsing. 2009-11-05 18:19:13 -08:00
Zachary T Welch 5e0ee6ab08 Improve at91sam3.c command argument parsing. 2009-11-05 18:03:20 -08:00
Zachary T Welch 93ab9ce888 Improve nand.c command argument parsing. 2009-11-05 18:03:20 -08:00
Zachary T Welch e9566a4a6a Improve flash.c command argument parsing. 2009-11-05 18:03:20 -08:00
Zachary T Welch 11e545f560 Add Flash/NAND bank command argument helpers.
This eliminates redundant code for parsing and retreiving the bank
specified from a script command argument.  This patch was written to
replace existing functionality; however, the parsing logic can be
updated later to allow flash commands to accept bank names as well as
their numbers.
2009-11-05 18:03:20 -08:00
Zachary T Welch 4189fdad28 Improve ETM tracemode update command. 2009-11-05 18:03:20 -08:00
Zachary T Welch d660721ba8 Improve etm command argument parsing. 2009-11-05 18:03:20 -08:00
Zachary T Welch 04b8a2a6f3 Improve trace command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch a8886cdfee Improve arm_adi_v5 command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 9b3781e5a4 Improve cortex_m3 command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch af84cd33a2 Improve xscale command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 4d67b0974f Improve arm11 command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch b699aef4c0 Improve arm966e command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch f8f1ac8865 Improve arm926ejs command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 714d92a954 Improve arm920t command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 0442bda216 Improve arm720t command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 11a0afc932 Improve arm7_9_common command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 3541ed3aa3 Improve armv7m command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 3dd5c59d7d Improve armv7a command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch b62ee5a3c5 Improve armv4_5 command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch ab33bdd46c Improve xscale command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 6e542407e7 Improve pld command argument parsing. 2009-11-05 18:03:19 -08:00
Zachary T Welch 2b78a4e82b Update all server port command to use new helper. 2009-11-05 18:03:19 -08:00
Zachary T Welch ae5732b9e4 Add server port command helper function. 2009-11-05 18:03:18 -08:00
Zachary T Welch 653ea7b25c Improve target.c command argument parsing.
Passes cmd_ctx into parse_load_image_command_args for reporting the
parsing errors therein.
2009-11-05 18:03:18 -08:00
Zachary T Welch b7b561aae8 Improve jtag command argument parsing. 2009-11-05 18:03:18 -08:00
Zachary T Welch f6f1dbfafd Improve debug_level command argument parsing. 2009-11-05 18:03:18 -08:00
Zachary T Welch 36a3646c22 Add macro for parsing numeric command arguments.
This helper eliminates significant amount of redundant code in command
handler functions throughout the system.  It wraps the lower-level
parse_* macros to implement a policy for reporting parse errors to the
active command context (cmd_ctx).  If errors do occur, this macro causes
the calling function to abort with the proper return code.
2009-11-05 17:27:25 -08:00
Zachary T Welch 68785af4da Add stringify macros in src/helper/types.h. 2009-11-05 17:20:18 -08:00
Øyvind Harboe 0f3117c19d arm920t: add mrcmcr interface fn's.
The arm920t has a concept of read modify write cycles
that may have to be represented in the mrcmcr interface
eventually.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:57:49 +01:00
Øyvind Harboe dc98c64d71 arm11: check if target is halted before executing mrc/mcr commands.
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:57:49 +01:00
Øyvind Harboe 051eaf7950 target: fix ordering of arguments to mcr and mrc commands
Now matches machine code syntax and old arm11 syntax.

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:57:49 +01:00
Øyvind Harboe 4e3c2676f1 target: check args to mrc/mcr.
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:57:49 +01:00
Øyvind Harboe 4441c1ffdc ARM11: added mrc/mcr support to arm11 code.
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:57:49 +01:00
Øyvind Harboe cca7cf1e74 TODO: Wrote up list of remaining tasks for target->type->mrc/mcr
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:56:37 +01:00
Øyvind Harboe b64503e37f target: Only register mrc mcr commands when one of the targets support them.
This avoids polluting help for targets that can never support mrc/mcr

Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:56:37 +01:00
Øyvind Harboe 1ebdc24494 cortex_a8: add mrc mcr interface.
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2009-11-05 23:56:37 +01:00
David Brownell afed39c0fe User's Guide: TAP setup tweakage
Highlight that the "-expected-id" probably comes from vendor
documentation, and that it *should* be used where possible.

Don't use ircapture/irmask in examples, to help discourage
use of those params when they're not required.  Explain a
bit better about why/when those params get used.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2009-11-05 11:31:32 -08:00
David Brownell 98788d7a75 watchpoint_add() cleanup
Fail watchpoint_add() if it's the same address but the
parameters are different ... don't just assume having
the same address means the same watchpoint!  (Note that
overlapping watchpoints aren't detected...)

Handle unrecognized return codes more sanely; don't exit()!
And describe command params right.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2009-11-05 01:47:44 -08:00
David Brownell 16b4b8cf54 Cortex-M3: expose most DWT registers
Expose most DWT registers via Tcl; there are a few more, but
those are mostly for profiling along with the ITM.  Having
this set available enables operations which aren't possible
with just the standard watchpoint operations.

The cycle counter may be interesting.  Turn it on after reset
by setting the LSB of the dwt_ctrl register, and it counts
CPU clocks.  You can program the comparator 0 watchpoint to
trigger on a given cycle count, rather than a data address.

Likewise, comparator 1 may be able to match data values given
address matches from one or two other comparators.  (Not all
hardware supports this capability though; try it.  That is
something the standard watchpoint methods should eventually
handle, for the single address case.)

Minor cleanup:  remove needless functional indirection for
exposing the v7m architctural registers.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2009-11-05 01:04:08 -08:00
David Brownell 8fb2baaa6b Cortex-M3: minor cleanup
There's no reason to read which interrupts are enabled from
the NVIC; that state isn't used.  Plus, it's highly dynamic
since firmware can change it at any time; remove the support
for those state records.

Remove duplicate definition of DWT_CTRL address; shrink a line.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2009-11-05 01:03:54 -08:00
David Brownell 7acb2607ff Cortex-M3: DWT cleanup/fixes
Fix the watchpoint error checks, and do them in add(), not later
in set() when it's mostly too late.  Support the full range of
watchpoint sizes (1 to 32K bytes each), and check alignments.

Minor cleanup of DWT access:  shrink lines, use "+" for address
calculations, comment a few issues.  Add debug message reporting
DWT capabilities, matching the message for FBP, and some minor
code and spec review comments.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2009-11-05 01:03:17 -08:00
David Brownell ff50caa8fa ARMv7M: add docs, remove exports
Add Doxygen for the exported ARMv7-M interfaces.

Make the non-exported stuff static.  Remove functions and
data which are now observably unused.

Add comment about a small speedup that the run_algorithm()
logic could use.  Shrink a few too-long lines.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2009-11-05 01:02:52 -08:00