summaryrefslogtreecommitdiff
path: root/src/target
Commit message (Collapse)AuthorAgeFilesLines
* swjdp_reg_t -> struct swjdp_regZachary T Welch2009-11-131-2/+2
| | | | Remove misleading typedef and redundant suffix from struct swjdp_reg.
* arm9tdmi_common_t -> struct arm9tdmi_commonZachary T Welch2009-11-139-13/+13
| | | | Remove misleading typedef and redundant suffix from struct arm9tdmi_common.
* arm966e_common_t -> struct arm966e_commonZachary T Welch2009-11-133-10/+10
| | | | Remove misleading typedef and redundant suffix from struct arm966e_common.
* arm926ejs_common_t -> struct arm926ejs_commonZachary T Welch2009-11-133-23/+23
| | | | Remove misleading typedef and redundant suffix from struct arm926ejs_common.
* arm920t_tlb_entry_t -> struct arm920t_tlb_entryZachary T Welch2009-11-132-3/+3
| | | | Remove misleading typedef and redundant suffix from struct arm920t_tlb_entry.
* arm920t_cache_line_t -> struct arm920t_cache_lineZachary T Welch2009-11-132-3/+3
| | | | Remove misleading typedef and redundant suffix from struct arm920t_cache_line.
* arm7tdmi_common_t -> struct arm7tdmi_commonZachary T Welch2009-11-134-8/+8
| | | | Remove misleading typedef and redundant suffix from struct arm7tdmi_common.
* arm7_9_common_t -> struct arm7_9_commonZachary T Welch2009-11-1314-136/+136
| | | | Remove misleading typedef and redundant suffix from struct arm7_9_common.
* arm720t_common_t -> struct arm720t_commonZachary T Welch2009-11-132-16/+16
| | | | Remove misleading typedef and redundant suffix from struct arm720t_common.
* arm11_sc7_action_t -> struct arm11_sc7_actionZachary T Welch2009-11-133-10/+10
| | | | Remove misleading typedef and redundant suffix from struct arm11_sc7_action.
* arm11_reg_state_t -> struct arm11_reg_stateZachary T Welch2009-11-132-9/+9
| | | | Remove misleading typedef and redundant suffix from struct arm11_reg_state.
* arm11_common_t -> struct arm11_commonZachary T Welch2009-11-134-80/+80
| | | | Remove misleading typedef and redundant suffix from struct arm11_common.
* arm11_reg_defs_t -> struct arm11_reg_defsZachary T Welch2009-11-131-6/+6
| | | | Remove misleading typedef and redundant suffix from struct arm11_reg_defs.
* reg_param_t -> struct reg_paramZachary T Welch2009-11-1314-26/+26
| | | | Remove misleading typedef and redundant suffix from struct reg_param.
* mem_param_t -> struct mem_paramZachary T Welch2009-11-1314-21/+21
| | | | Remove misleading typedef and redundant suffix from struct mem_param.
* arm920t_common_t -> struct arm920t_commonZachary T Welch2009-11-133-24/+24
| | | | Remove misleading typedef and redundant suffix from struct arm920t_common.
* arm11_register_history_t -> struct arm11_register_historyZachary T Welch2009-11-131-3/+3
| | | | Remove misleading typedef and redundant suffix from struct arm11_register_history.
* scan_field_t -> struct scan_fieldZachary T Welch2009-11-1318-67/+67
| | | | Remove useless structure typedef.
* jtag_tap_t -> struct jtag_tapZachary T Welch2009-11-1333-58/+58
| | | | | Search and destroy the jtag_tap_t typedef. This also cleans up a layering violation, removing the declaration from types.h.
* fileio_t -> struct fileioZachary T Welch2009-11-135-11/+11
| | | | Remove useless structure typedef.
* remove accidental artifactZachary T Welch2009-11-131-0/+0
| | | | | Somehow I managed to slip a temporary build file into the tree. Remove it and update the .gitignore file so it doesn't happen again.
* command_handler_t: make argc unsignedZachary T Welch2009-11-131-3/+3
| | | | | | The number of command arguments will always be 0 or more, so use the right type in handlers. This has a cascading effect up through the layers, but the new COMMAND_HANDLER macros prevented total chaos.
* add CMD_NAME macro for command handlersZachary T Welch2009-11-137-16/+16
| | | | | By introducing the CMD_NAME macro, this parameter may be integrated as args[-1] in command.[ch], without touching any other call sites.
* use CALL_COMMAND_HANDLER instead of direct callsZachary T Welch2009-11-133-9/+10
| | | | | | By using CALL_COMMAND_HANDLER, parameters can be reordered, added, or even removed in inherited signatures, without requiring revisiting all of the various call sites.
* s3c24xx: use COMMAND_HANDLER with command helperZachary T Welch2009-11-131-0/+0
| | | | | Add S3C24XX_DEVICE_COMMAND macros to abstract common command handler conventions.
* arm_adi,armv7[am]: use COMMAND_HELPER for helpersZachary T Welch2009-11-134-23/+18
| | | | | Rewrites the dap_* command helpers to use the COMMAND_HELPER paradigm. Uses CALL_COMMAND_HELPER to hide inherited calling conventions.
* use COMMAND_HELPER for command helper functionsZachary T Welch2009-11-133-12/+9
| | | | | Define the numerous helpers that inherit command handler parameters using the COMMAND_HELPER macro.
* use COMMAND_HANDLER macro to define all commandsZachary T Welch2009-11-1320-158/+93
|
* Cortex-A8: fix indentDavid Brownell2009-11-131-28/+28
| | | | | | | The "remove (forward) declarations" patch goofed indentation on the "cortexa8_target" struct; fix. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ETM: start support for ETMv2+David Brownell2009-11-122-23/+129
| | | | | | | | | | | | | | | | | ARM11 and newer cores include updated ETM modules. Recognize their version codes and some key config differences. Sanity checked on an OMAP2, with an ETM11RV r0p1 (ETMv3.1). This still handles only scan chain 6, with at most 128 registers. Newer cores (mostly, Cortex) will need to use the DAP instead. Note that the newer ETM modules don't quite fit the quirky config model of the older ones ... having more port widths is easy, but the modes aren't the same. That still needs to change. Fix a curious bug ... how did the register cache NOT get saved?? Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ETM: remove old mid-level ETM handleDavid Brownell2009-11-117-11/+8
| | | | | | | | | | | | | | | | | | Now that nothing uses the old ETM handle any more, remove it. Add minimal header tweaks, letting non-ARM7 and non-ARM9 cores access ETM facilities. Now ARM11 could support standard ETM (and ETB) access as soon as it derives from "struct arm" ... its scanchain 6 is used access the ETM, just like ARM7 and ARM9. The Cortex parts (both M3 and A8) will need modified access methods (via ETM init parameters), so they use the DAP. Our first A8 target (OMAP3) needs that for both ETM and ETB, but the M3 ETM isn't very useful without SWO trace support (it's painfully stripped down), so that support won't be worth adding for a while. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ETM: use new toplevel ETM handleDavid Brownell2009-11-111-58/+50
| | | | | | | | Make ETM itself use the new toplevel ETM handle, instead of the to-be-removed lower level one. As of this patch, nothing should be using the old ARM7/ARM9-specific handle. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ETM: update port driversDavid Brownell2009-11-113-42/+41
| | | | | | | | | | Make both useful ETM port drivers (etb, etm_dummy) use the new toplevel ETM handle, instead of the to-be-removed lower level one. Do the same for the "oocd-trace" prototype too; and fix its error reporting paths: return failure codes, don't exit(), etc Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ETM: update arm[79]tdmi_examine()David Brownell2009-11-112-8/+10
| | | | | | | Make ARM7 and ARM9 cores use the new toplevel ETM handle to trigger ETM setup, not the to-be-removed lower level one. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ARM: start generalized base typeDavid Brownell2009-11-112-19/+34
| | | | | | | | | | | | | | | | Rename "struct armv4_5_common_s" as "struct arm". It needs a bit more work to be properly generic, and to move out of this header, but it's the best start we have on that today. Add and initialize an optional ETM pointer, since that will be the first thing that gets generalized. The intent being: all ARMs should eventually derive from this "struct arm", so they can reuse the current ETM logic. (And later, more.) Currently the ARM cores that *don't* so derive are only ARMv7-M (and thus Cortex-M3) and ARM11. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* remove more useless declarationsZachary T Welch2009-11-111-13/+12
| | | | | Removes forward declarations by moving command registration after defintion of the command handlers.
* cortex_a8: remove declarations, use static keywordZachary T Welch2009-11-112-112/+82
|
* add const keyword to some APIsZachary T Welch2009-11-115-7/+9
| | | | | | Add 'const' keyword to 'char *' parameters to allow command handlers to pass constant string arguments. These changes allow the 'args' command handler to be changed to 'const' in a subsequent patch.
* change argv to args in command handlersZachary T Welch2009-11-111-5/+5
| | | | | | | | | | | Subsequent patches expect all command handlers to use a uniform parameter naming scheme. In the entire tree, these two files used standard 'argv' instead of our non-standard 'args'. This patch opts to reduces the noise required to unify the command handlers, using dominant 'args' form. A future patch may be used to convert us back to the standard argv, but that requires coordination with all developers to minimize disruptions.
* makefiles: improve build orderZachary T Welch2009-11-111-51/+76
| | | | | | | | | | | Separates various groups of files to be built in logical succession. In each layer, the core module (target.c, nand.c, etc.) is built _after_ their helper modules (e.g. image.c, nand_ecc.c) but _before_ any of their drivers (e.g. arm966e.c, mx3_nand.c). This allows problems introduced at the bottom of the stack to result in build failures as soon as possible, as the helpers and core should wrap portions of them.
* ETM cleanupDavid Brownell2009-11-114-131/+120
| | | | | | | | | | | | | | | | Various cleanups of ETM related code. - Saner error return paths - Simplify arm7_9 init ... no need for extra zeroing! - Shrink some lines - Tweak some diagnostics - Use shorter name for ETM struct type. - Don't exit() and similar. The diagnostics look forward to having this ETM code work with more than just ARM7/ARM9. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* fix bug in ARM720: bugfixZachary T Welch2009-11-101-1/+1
|
* ARM720: bugfixDavid Brownell2009-11-101-1/+2
| | | | | | | The "ARM720 uses the new inheritance/nesting scheme" patch wrongly scrubbed a calloc() from arm720t_target_create(). Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* target: MMU-aware init for memory read/writeDavid Brownell2009-11-101-23/+42
| | | | | | | | | | | | | | | | | | Start switching MMU handling over to a more sensible scheme. Having an mmu() method enables MMU-aware behaviors. Not having one kicks in simpler ones, with no distinction between virtual and physical addresses. Currently only a handful of targets have methods to read/write physical memory: just arm720, arm920, and arm926. They should all initialize OK now, but the arm*20 parts don't do the "extra" stuff arm926 does (which should arguably be target-generic). Also simplify how target_init() loops over all targets by making it be a normal "for" loop, instead of scattering its three parts to the four winds. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* arm11: add etmr/etmw registers to access ETM via DBGTAP scan chainMichael Bruck2009-11-103-0/+142
| | | | | | | | First cut of these commands. Øyvind tinkered a bit with the number parsing to bring it up to speed + rebased it. Ready for testing. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
* ARM11: remove old mrc/mcr commandsØyvind Harboe2009-11-101-102/+0
| | | | | | Switch to new commands in config scripts Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
* Target: minor cleanupDavid Brownell2009-11-102-13/+21
| | | | | | | | - improve some names -- a "default" prefix is not descriptive - add doxygen @todo entries for some issues - avr8 isn't ever going to need those MMU hooks Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ARM920: implement basic MMU opsDavid Brownell2009-11-101-0/+22
| | | | | | mmu() works; virt2phys() fails and logs an error. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* ARM720: implement basic MMU opsDavid Brownell2009-11-101-0/+22
| | | | | | mmu() works; virt2phys() fails and logs an error. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
* Target: fix bad error messagesDavid Brownell2009-11-101-7/+10
| | | | | | And shrink a few too-long lines. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>