1. 12 Nov, 2009 5 commits
    • David Brownell's avatar
      ETM: remove old mid-level ETM handle · 5723e54f
      David Brownell authored
      
      
      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: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      5723e54f
    • David Brownell's avatar
      ETM: use new toplevel ETM handle · e7405365
      David Brownell authored
      
      
      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: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      e7405365
    • David Brownell's avatar
      ETM: update port drivers · 9855a11e
      David Brownell authored
      
      
      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: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      9855a11e
    • David Brownell's avatar
      ETM: update arm[79]tdmi_examine() · 3ae44019
      David Brownell authored
      
      
      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: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      3ae44019
    • David Brownell's avatar
      ARM: start generalized base type · 4b20ed6b
      David Brownell authored
      
      
      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: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      4b20ed6b
  2. 11 Nov, 2009 8 commits
    • Zachary T Welch's avatar
      remove more useless declarations · 39ab1c1a
      Zachary T Welch authored
      Removes forward declarations by moving command registration after
      defintion of the command handlers.
      39ab1c1a
    • Zachary T Welch's avatar
      e9974316
    • Zachary T Welch's avatar
      add const keyword to some APIs · ca594adb
      Zachary T Welch authored
      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.
      ca594adb
    • Zachary T Welch's avatar
      change argv to args in command handlers · 9741e126
      Zachary T Welch authored
      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.
      9741e126
    • Zachary T Welch's avatar
      makefiles: improve build order · b7b4efcd
      Zachary T Welch authored
      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.
      b7b4efcd
    • David Brownell's avatar
      ETM cleanup · d796ce0e
      David Brownell authored
      
      
      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: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      d796ce0e
    • Zachary T Welch's avatar
      fix bug in ARM720: bugfix · 583a293a
      Zachary T Welch authored
      583a293a
    • David Brownell's avatar
      ARM720: bugfix · d570e4f6
      David Brownell authored
      
      
      The "ARM720 uses the new inheritance/nesting scheme" patch
      wrongly scrubbed a calloc() from arm720t_target_create().
      
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      d570e4f6
  3. 10 Nov, 2009 9 commits
  4. 09 Nov, 2009 6 commits
    • David Brownell's avatar
      Revert "target: add target->type->has_mmu fn" · 7269ba5e
      David Brownell authored
      
      
      This patch introduced a bug preventing flash writes from working
      on Cortex-M3 targets like the STM32.  Moreover, it's the wrong
      approach for handling no-MMU targets.
      
      The right way to handle no-MMU targets is to provide accessors
      for physical addresses, and use them everywhere; and any code
      which tries to work with virtual-to-physical mappings should use
      a identity mapping (which can be defaulted).
      
      And ... we can tell if a target has an MMU by seeing if it's
      got an mmu() method.  No such methood means no MMU.
      
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      7269ba5e
    • David Brownell's avatar
      finish removing deprecated/obsolete commands · d70d9634
      David Brownell authored
      
      
      It's been about a year since these were deprecated and, in most
      cases, removed.  There's no point in carrying that documentation,
      or backwards compatibility for "jtag_device" and "jtag_speed",
      around forever.  (Or a few remnants of obsolete code...)
      
      Removed a few obsolete uses of "jtag_speed":
      
       - The Calao stuff hasn't worked since July 2008.  (Those Atmel
         targets need to work with a 32KHz core clock after reset until
         board-specific init-reset code sets up the PLL and enables a
         faster JTAg clock.)
       - Parport speed controls don't actually work (tops out at about
         1 MHz on typical HW).
       - In general, speed controls need to live in board.cfg files (or
         sometimes target.cfg files), not interface.cfg ...
      
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      d70d9634
    • Zachary T Welch's avatar
      src/target: remove 'extern' and wrap headers · 3885ab5a
      Zachary T Welch authored
      Remove extern keywords from function prototypes and wrap long lines.
      3885ab5a
    • Zachary T Welch's avatar
      target.h: remove extern keyword and wrap · 42cafc93
      Zachary T Welch authored
      Removes 'extern' keyword from function prototypes and wraps long lines.
      42cafc93
    • David Brownell's avatar
      EmbeddedICE: minor cleanups · 526347f9
      David Brownell authored
      
      
      Add comments (Doxygen and normal), remove unused code,
      shrink some overlong lines.  Get rid of a forward decl.
      
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      526347f9
    • Zachary T Welch's avatar
      Overhaul time support API · 2689f58f
      Zachary T Welch authored
      This patch changes the duration_* API in several ways.  First, it
      updates the API to use better names.  Second, string formatting has
      been removed from the API (with its associated malloc).  Finally, a
      new function added to convert the time into seconds, which can be
      used (or formatted) by the caller.  This eliminates hidden calls to
      malloc that require associated calls to free().
      
      This patch also removes the useless extern keyword from prototypes,
      and it eliminates the duration_t typedef (use 'struct duration').
      These API also allows proper error checking, as it is possible for
      gettimeofday to fail in certain circumstances.
      
      The consumers have all been chased to use this new API as well, as
      there were relatively few cases doing this type of measurement.
      In most cases, the code performs additional checks for errors, but
      the calling code looks much cleaner in every case.
      2689f58f
  5. 08 Nov, 2009 4 commits
  6. 06 Nov, 2009 8 commits