X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=src%2Ftarget%2Farmv7a.h;h=f93245634adb3bd147f9f076b4c1cfa1f779af06;hb=f6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab;hp=9158d787c04aa799272a3d83e6a88fac833f8d1e;hpb=98eea5680b491a26812214ddfeeafb3f088b94aa;p=fw%2Fopenocd diff --git a/src/target/armv7a.h b/src/target/armv7a.h index 9158d787c..f93245634 100644 --- a/src/target/armv7a.h +++ b/src/target/armv7a.h @@ -19,11 +19,11 @@ #ifndef ARMV7A_H #define ARMV7A_H -#include -#include "armv4_5.h" +#include "arm_adi_v5.h" +#include "arm.h" #include "armv4_5_mmu.h" #include "armv4_5_cache.h" -#include +#include "arm_dpm.h" enum { @@ -50,8 +50,7 @@ struct armv7a_common int common_magic; struct reg_cache *core_cache; - /* arm adp debug port */ - struct swjdp_common swjdp_info; + struct adiv5_dap dap; /* Core Debug Unit */ struct arm_dpm dpm; @@ -63,11 +62,9 @@ struct armv7a_common struct armv4_5_mmu_common armv4_5_mmu; int (*examine_debug_reason)(struct target *target); - void (*post_debug_entry)(struct target *target); + int (*post_debug_entry)(struct target *target); void (*pre_restore_context)(struct target *target); - void (*post_restore_context)(struct target *target); - }; static inline struct armv7a_common * @@ -114,32 +111,6 @@ target_to_armv7a(struct target *target) /* See ARMv7a arch spec section C10.8 */ #define CPUDBG_AUTHSTATUS 0xFB8 -/* DSCR bit numbers (See ARMv7a arch spec section 12.4.5) */ -#define DSCR_CORE_HALTED 0 -#define DSCR_CORE_RESTARTED 1 -#define DSCR_EXT_INT_EN 13 -#define DSCR_HALT_DBG_MODE 14 -#define DSCR_MON_DBG_MODE 15 -#define DSCR_INSTR_COMP 24 -#define DSCR_DTR_TX_FULL 29 -#define DSCR_DTR_RX_FULL 30 - -struct armv7a_algorithm -{ - int common_magic; - - enum armv4_5_mode core_mode; - enum armv4_5_state core_state; -}; - -struct armv7a_core_reg -{ - int num; - enum armv4_5_mode mode; - struct target *target; - struct armv7a_common *armv7a_common; -}; - int armv7a_arch_state(struct target *target); struct reg_cache *armv7a_build_reg_cache(struct target *target, struct armv7a_common *armv7a_common);