aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2010-04-10NAND/MX3: review scope of dataAntonio Borneo
Add "static" qualifier to private data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10NOR/ADUC702X: review scope of dataAntonio Borneo
Add "static" qualifier to private data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10NOR/AVRF: review scope of dataAntonio Borneo
Add "static" qualifier to private data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10NOR/CORE: review scope of dataAntonio Borneo
Add "static" qualifier to private data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10NOR/DRIVERS: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Remove unused "extern" in src/ecosboard.c Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10STR9XPEC: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10TCL: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10TIME_SUPPORT: review unused symbolsAntonio Borneo
Remove unused functions: - timeval_add Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10HELLO: review unused symbolsAntonio Borneo
Remove unused functions: - hello_register_commands Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10PLD: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ADI_V5_JTAG: review scope of dataAntonio Borneo
Add "static" qualifier to private data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ARM920T: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ARM_JTAG: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ARM_SIMULATOR: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ARMV4_5_MMU: review unused symbolsAntonio Borneo
Remove unused data: - armv4_5_mmu_page_type_names Remove prototype of not existing function: - armv4mmu_translate_va Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ARMV4_5: review scope of dataAntonio Borneo
Add "static" qualifier to private data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10EMBEDDEDICE: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10TARGET: review unused symbolsAntonio Borneo
Remove unused functions: - target_all_handle_event Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10TARGET: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Remove unused "extern" in src/ecosboard.c Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-10ARMv7M: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-04-04Restore deleted '!' characterDavid Brownell
I'm not sure what caused this significant character to get deleted. it may be related to intermittent Editor or terminal flakes I've been seeing lately (sigh). This fix is trivial. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-04-04target: are we running algorithm code?David Brownell
Fixing one bug can easily uncover another .... in this case, making sure that we properly invalidate some cached NOR state when resuming arbitrary target code turned up an issue when the code wasn't quite arbitrary (and we couldn't know that, but some parts of OpenOCD assumed the cache would not be invalidated. Specifically: some flash drivers (like CFI) update that state in loops with downloaded algorithms, thus invalidating the state as it's probed. + Add a new target state flag, to record whether the target is running downloaded algorithm code. + Use that flag to add a special case: "trust" downloaded algorithms not to corrupt that cached state, bypassing cache invalidation. Also update some of the documentation to stipulate that this flavor of trustworthiness is now *required* ... not just a fortuitous acident. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-04-04simplify and unconfuse target_run_algorithm()David Brownell
For some reason there are *two* schemes for interposing logic into the run_algorithm() code path... One is a standard procedural wapper around the target method invocation. the other (superfluous) one hacked the method table by splicing a second procedural wrapper into the method table. Remove it: * Rename its slightly-more-featureful wrapper so it becomes the standard procedural wrapper, leaving its added logic (where it should have been in the first place. Also add a paranoia check, to report targets that don't support algorithms without traversing a NULL pointer, and tweak its code structure a bit so it's easier to modify. * Get rid of the superfluous/conusing method table hacks. This is a net simplification, making it simpler to analyse what's going on, and then interpose logic . ... by ensuring there's only one natural place for it to live. ------------ Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-04-03buildfixDavid Brownell
Without this, a system using gcc (GCC) 4.2.4 (Ubuntu 4.2.4-1ubuntu4) aborts builds after reporting: tcl.c: In function ‘handle_irscan_command’: tcl.c:1168: warning: passing argument 1 of ‘buf_set_u32’ discards qualifiers from pointer target type Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-03-29xscale: fix trace buffer functionality when resuming from a breakpointMike Dunn
Problem: halt at a breakpoint, enable trace buffer ('xscale trace_buffer enable fill'), then resume. Wait for debug exception when trace buffer fills (if not sooner due to another breakpoint, vector catch, etc). Instead, never halts. When halted explicitly from OpenOCD and trace buffer dumped, it contains only one entry; a branch to the address of the original breakpoint. If the above steps are repeated, except that the breakpoint is removed before resuming, the trace buffer fills and the debug exception is generated, as expected. Cause: related to how a breakpoint is stepped over on resume. The breakpoint is temporarily removed, and a hardware breakpoint is set on the next instruction that will execute. xscale_debug_entry() is called when that breakpoint hits. This function checks if the trace buffer is enabled, and if so reads the trace buffer from the target and then disables the trace (unless multiple trace buffers are specified by the user when trace is enabled). Thus you only trace one instruction before it is disabled. Solution: kind of a hack on top of a hack, but it's simple. Anything better would involve some refactoring. This has been tested and trace now works as intended, except that the very first instruction is not part of the trace when resuming from a breakpoint. TODO: still many issues with trace: doesn't work during single-stepping (trace buffer is flushed each step), 'xscale analyze_trace' works only marginally for a trace captured in 'fill' mode, and not at all for a trace captured in 'wrap' mode. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-27jtag/tcl.c cleanup -- split out "adapter.c"David Brownell
Clean up the jtag/tcl.c file, which was one of the biggest and messiest ones in that directory. Do it by splitting out all the generic adapter commands to a separate "adapter.c" file (leaving the "tcl.c" file holding only JTAG utilities). Also rename the little-used "jtag interface" to "adapter_name", which should have been at least re-categorized earlier (it's not jtag-only). Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-03-26NOR TCL: fix usage messageAntonio Borneo
The command "flash bank" has updated syntax. Add the mandatory parameter <target> to the usage message that prints in case of error. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-03-26TCL scripts: update to current "flash bank" syntaxAntonio Borneo
While "flash bank" syntax has been changed long ago, several tcl script are still not fully update. Fix following cases related with "cfi" driver: - syntax error: the mandatory <name> parameter is missing - warning: the <target> parameter is a number, instead of the target name - the comment line above the command does not report actual syntax Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-03-25zy1000: dev toolØyvind Harboe
first cut peek/poke over tcp/ip, used for debug/research purposes only. Long term JTAG over TCP/IP might be an offshoot. The performance is usable for development/testing purposes. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-25target: fix poll offØyvind Harboe
I don't know when "poll off" broke, but "poll off" didn't stop background polling of target. The polling status flag simply wasn't checked in the handle_target timer callback. All target polling(including power/reset state) is now stopped upon "poll off". Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-25change %x and %d to PRIx32 and PRId32 where needed for cygwinDaniel Bäder
2010-03-25zy1000: allow it to build on linux host for testing purposesØyvind Harboe
For testing and checking the build this can be useful, it doesn't have any practical application outside development. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-25telnet_server: review unused symbolsAntonio Borneo
Remove unused function Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-03-25telnet_server: review scope of functionsAntonio Borneo
Add "static" qualifier to private functions. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-03-24FT2232 Messaaging fixDavid Brownell
The init cleanup patch overlooked a message which was wrongly specific to the "usbjtag" layout. Fix. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-03-24server: review unused symbolsAntonio Borneo
Remove unused function Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-03-24server: review scope of functions and dataAntonio Borneo
Add "static" qualifier to private functions and data. Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
2010-03-22zy1000: fix optimisaion bug in dcc writesØyvind Harboe
Introduced & corrected since 0.4. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-22fix software breakpoints on xscaleMike Dunn
This patch fixes xscale software breakpoints by cleaning the dcache and invalidating the icache after the bkpt instruction is inserted or removed. The icache operation is necessary in order to flush the fetch buffers, even if the icache is disabled (see section 4.2.7 of the xscale core developer's manual). The dcache is presumed to be enabled; no harm done if not. The dcache is also invalidated after cleaning in order to safeguard against a future load of invalid data, in the event that cache_clean_address points to memory that is valid and in use. Also corrected a confusing typo I noticed in a comment. TODO (or not TODO...?): the xscale's 2K "mini dcache" is not cleaned. This cache is not used unless the 'X' bit in the page table entry is set. This is a proprietary xscale extension to the ARM architecture. If a target's OS or executive makes use of this for memory regions holding code, the breakpoint problem will persist. Flushing the mini dcache requires that 2K of valid cacheable memory (mapped with 'X' bit set) be designated by the user for this purpose. The debug handler that gets downloaded to the target will also need to be extended.
2010-03-22bitq: fix warning now that out_value is constØyvind Harboe
This was an easy one. Just add the missing "const" to a local variable definition. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-21ft2232 init mess cleanupDavid Brownell
In the ft2232 driver, initialization for many layouts punts to a routine called usbjtag_init(), instead of a routine specific to each layout. That routine is a mess built around a "what type layout am I" core. That's a bad design ... in this case, especially so, since it bypasses the layout-specific dispatch which was just done, and obfuscates the initialization which is at least somewhat generic, instead of being specific to the "usbjtag" layout. Split and document out the generic parts of usbjtag_init(), and make the rest of those layouts have layout-specific init methods. Also, rename usbjtag_reset() ... that also was not specific to the "usbjtag" layout, and thus contributed to the previous code structure confusion. (Eventually, all layout-specific code (and method tables) should probably live in files specific to each layout. These changes will facilitate those and other cleanups to this driver.) Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-03-21arm breakpoints: amended fix commentØyvind Harboe
the handling of caches, should be moved into the breakpoint specific callbacks rather than being plonked into generic memory write fn's. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-21jtag: make out_value constØyvind Harboe
Tightens up the jtag_add_xxx_scan() API Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-20jtag: move towards making out_value constØyvind Harboe
These were relatively straightforward fixes which are backwards compatible. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-19FT2232 comment tweaksDavid Brownell
Note that the FT4232 chips have four channels not two, and Elaborate on uses of the additional channels. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
2010-03-19zy1000: clean up jtag_add_xx_scan fn'sØyvind Harboe
The implementation is now more straightforward as the scan_fields have been greatly simplified over time. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-19zy1000: fix bug in end state of DCC writesØyvind Harboe
Introduced in latest commits, found by code inspection & GCC warning. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-19jtag: retire jtag_get/set_end_state()Øyvind Harboe
Voila! This get rids of mysteries about what what state the TAP is in. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-19jtag: remove jtag_get_end_state() usageØyvind Harboe
Code inspection indicated what constant end states to use. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
2010-03-19jtag: get rid of unecessary jtag_get_end_state()Øyvind Harboe
By code inspection. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>