X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Ftarget%2Farm7_9_common.h;h=a49dab2739e43402dd0c822e7e2c74c5c027236a;hb=5eb638c71e95048b090b8a19640d7d4902c07902;hp=80f8fc74807d10812fed7e4b22dddc8d58b96cec;hpb=acff2521fb8e47dce4a2e89e2de77e71bf314047;p=openocd.git diff --git a/src/target/arm7_9_common.h b/src/target/arm7_9_common.h index 80f8fc7480..a49dab2739 100644 --- a/src/target/arm7_9_common.h +++ b/src/target/arm7_9_common.h @@ -30,7 +30,7 @@ #define ARM7_9_COMMON_H #include "breakpoints.h" -#include "etm.h" +#include "armv4_5.h" #define ARM7_9_COMMON_MAGIC 0x0a790a79 /**< */ @@ -39,6 +39,7 @@ */ typedef struct arm7_9_common_s { + struct arm armv4_5_common; uint32_t common_magic; arm_jtag_t jtag_info; /**< JTAG information for target */ @@ -46,7 +47,6 @@ typedef struct arm7_9_common_s uint32_t arm_bkpt; /**< ARM breakpoint instruction */ uint16_t thumb_bkpt; /**< Thumb breakpoint instruction */ - bool force_hw_bkpts; int sw_breakpoints_added; /**< Specifies which watchpoint software breakpoints are setup on */ int sw_breakpoint_count; /**< keep track of number of software breakpoints we have set */ @@ -69,8 +69,6 @@ typedef struct arm7_9_common_s bool fast_memory_access; bool dcc_downloads; - etm_context_t *etm_ctx; - struct working_area_s *dcc_working_area; int (*examine_debug_reason)(target_t *target); /**< Function for determining why debug state was entered */ @@ -107,11 +105,16 @@ typedef struct arm7_9_common_s void (*pre_restore_context)(target_t *target); /**< Callback function called before restoring the processor context */ void (*post_restore_context)(target_t *target); /**< Callback function called after restoring the processor context */ - armv4_5_common_t armv4_5_common; - void *arch_info; } arm7_9_common_t; +static inline struct arm7_9_common_s * +target_to_arm7_9(struct target_s *target) +{ + return container_of(target->arch_info, struct arm7_9_common_s, + armv4_5_common); +} + int arm7_9_register_commands(struct command_context_s *cmd_ctx); int arm7_9_poll(target_t *target);