command_context_t -> struct command_context

Remove misleading typedef and redundant suffix from struct command_context.
This commit is contained in:
Zachary T Welch
2009-11-13 13:25:47 -08:00
parent d16968e24f
commit 98723c4ecd
116 changed files with 278 additions and 278 deletions
+2 -2
View File
@@ -1801,7 +1801,7 @@ static int arm11_target_create(struct target *target, Jim_Interp *interp)
return ERROR_OK;
}
static int arm11_init_target(struct command_context_s *cmd_ctx,
static int arm11_init_target(struct command_context *cmd_ctx,
struct target *target)
{
/* Initialize anything we can set up without talking to the target */
@@ -2239,7 +2239,7 @@ struct target_type arm11_target = {
};
int arm11_register_commands(struct command_context_s *cmd_ctx)
int arm11_register_commands(struct command_context *cmd_ctx)
{
FNC_INFO;
+1 -1
View File
@@ -182,7 +182,7 @@ struct arm11_reg_state
struct target * target;
};
int arm11_register_commands(struct command_context_s *cmd_ctx);
int arm11_register_commands(struct command_context *cmd_ctx);
int arm11_read_etm(struct arm11_common * arm11, uint8_t address, uint32_t *value);
int arm11_write_etm(struct arm11_common * arm11, uint8_t address, uint32_t value);
+3 -3
View File
@@ -211,7 +211,7 @@ static void arm720t_pre_restore_context(struct target *target)
arm720t_write_cp15(target, 0xee060f10, arm720t->far_reg);
}
static int arm720t_verify_pointer(struct command_context_s *cmd_ctx,
static int arm720t_verify_pointer(struct command_context *cmd_ctx,
struct arm720t_common *arm720t)
{
if (arm720t->common_magic != ARM720T_COMMON_MAGIC) {
@@ -371,7 +371,7 @@ static int arm720t_soft_reset_halt(struct target *target)
return ERROR_OK;
}
static int arm720t_init_target(struct command_context_s *cmd_ctx, struct target *target)
static int arm720t_init_target(struct command_context *cmd_ctx, struct target *target)
{
return arm7tdmi_init_target(cmd_ctx, target);
}
@@ -490,7 +490,7 @@ static int arm720t_mcr(struct target *target, int cpnum, uint32_t op1, uint32_t
return arm720t_write_cp15(target, mrc_opcode(cpnum, op1, op2, CRn, CRm), value);
}
static int arm720t_register_commands(struct command_context_s *cmd_ctx)
static int arm720t_register_commands(struct command_context *cmd_ctx)
{
int retval;
command_t *arm720t_cmd;
+1 -1
View File
@@ -3119,7 +3119,7 @@ int arm7_9_init_arch_info(struct target *target, struct arm7_9_common *arm7_9)
1, 1, target);
}
int arm7_9_register_commands(struct command_context_s *cmd_ctx)
int arm7_9_register_commands(struct command_context *cmd_ctx)
{
command_t *arm7_9_cmd;
+1 -1
View File
@@ -115,7 +115,7 @@ target_to_arm7_9(struct target *target)
armv4_5_common);
}
int arm7_9_register_commands(struct command_context_s *cmd_ctx);
int arm7_9_register_commands(struct command_context *cmd_ctx);
int arm7_9_poll(struct target *target);
+1 -1
View File
@@ -684,7 +684,7 @@ int arm7tdmi_examine(struct target *target)
return ERROR_OK;
}
int arm7tdmi_init_target(struct command_context_s *cmd_ctx, struct target *target)
int arm7tdmi_init_target(struct command_context *cmd_ctx, struct target *target)
{
arm7tdmi_build_reg_cache(target);
+1 -1
View File
@@ -34,7 +34,7 @@ struct arm7tdmi_common
};
int arm7tdmi_init_arch_info(struct target *target, struct arm7tdmi_common *arm7tdmi, struct jtag_tap *tap);
int arm7tdmi_init_target(struct command_context_s *cmd_ctx, struct target *target);
int arm7tdmi_init_target(struct command_context *cmd_ctx, struct target *target);
int arm7tdmi_examine(struct target *target);
#endif /* ARM7TDMI_H */
+2 -2
View File
@@ -415,7 +415,7 @@ void arm920t_pre_restore_context(struct target *target)
static const char arm920_not[] = "target is not an ARM920";
static int arm920t_verify_pointer(struct command_context_s *cmd_ctx,
static int arm920t_verify_pointer(struct command_context *cmd_ctx,
struct arm920t_common *arm920t)
{
if (arm920t->common_magic != ARM920T_COMMON_MAGIC) {
@@ -1348,7 +1348,7 @@ static int arm920t_mcr(struct target *target, int cpnum, uint32_t op1, uint32_t
}
/** Registers commands to access coprocessor, cache, and MMU resources. */
int arm920t_register_commands(struct command_context_s *cmd_ctx)
int arm920t_register_commands(struct command_context *cmd_ctx)
{
int retval;
command_t *arm920t_cmd;
+1 -1
View File
@@ -71,6 +71,6 @@ void arm920t_disable_mmu_caches(struct target *target,
int mmu, int d_u_cache, int i_cache);
void arm920t_enable_mmu_caches(struct target *target,
int mmu, int d_u_cache, int i_cache);
int arm920t_register_commands(struct command_context_s *cmd_ctx);
int arm920t_register_commands(struct command_context *cmd_ctx);
#endif /* ARM920T_H */
+2 -2
View File
@@ -474,7 +474,7 @@ static void arm926ejs_pre_restore_context(struct target *target)
static const char arm926_not[] = "target is not an ARM926";
static int arm926ejs_verify_pointer(struct command_context_s *cmd_ctx,
static int arm926ejs_verify_pointer(struct command_context *cmd_ctx,
struct arm926ejs_common *arm926)
{
if (arm926->common_magic != ARM926EJS_COMMON_MAGIC) {
@@ -818,7 +818,7 @@ static int arm926ejs_mmu(struct target *target, int *enabled)
}
/** Registers commands to access coprocessor, cache, and debug resources. */
int arm926ejs_register_commands(struct command_context_s *cmd_ctx)
int arm926ejs_register_commands(struct command_context *cmd_ctx)
{
int retval;
command_t *arm926ejs_cmd;
+1 -1
View File
@@ -48,7 +48,7 @@ target_to_arm926(struct target *target)
int arm926ejs_init_arch_info(struct target *target,
struct arm926ejs_common *arm926ejs, struct jtag_tap *tap);
int arm926ejs_register_commands(struct command_context_s *cmd_ctx);
int arm926ejs_register_commands(struct command_context *cmd_ctx);
int arm926ejs_arch_state(struct target *target);
int arm926ejs_write_memory(struct target *target,
uint32_t address, uint32_t size, uint32_t count, uint8_t *buffer);
+2 -2
View File
@@ -57,7 +57,7 @@ static int arm966e_target_create(struct target *target, Jim_Interp *interp)
return arm966e_init_arch_info(target, arm966e, target->tap);
}
static int arm966e_verify_pointer(struct command_context_s *cmd_ctx,
static int arm966e_verify_pointer(struct command_context *cmd_ctx,
struct arm966e_common *arm966e)
{
if (arm966e->common_magic != ARM966E_COMMON_MAGIC) {
@@ -216,7 +216,7 @@ COMMAND_HANDLER(arm966e_handle_cp15_command)
}
/** Registers commands used to access coprocessor resources. */
int arm966e_register_commands(struct command_context_s *cmd_ctx)
int arm966e_register_commands(struct command_context *cmd_ctx)
{
int retval;
command_t *arm966e_cmd;
+1 -1
View File
@@ -43,7 +43,7 @@ target_to_arm966(struct target *target)
int arm966e_init_arch_info(struct target *target,
struct arm966e_common *arm966e, struct jtag_tap *tap);
int arm966e_register_commands(struct command_context_s *cmd_ctx);
int arm966e_register_commands(struct command_context *cmd_ctx);
int arm966e_write_cp15(struct target *target, int reg_addr, uint32_t value);
#endif /* ARM966E_H */
+2 -2
View File
@@ -779,7 +779,7 @@ int arm9tdmi_examine(struct target *target)
return ERROR_OK;
}
int arm9tdmi_init_target(struct command_context_s *cmd_ctx,
int arm9tdmi_init_target(struct command_context *cmd_ctx,
struct target *target)
{
arm9tdmi_build_reg_cache(target);
@@ -936,7 +936,7 @@ COMMAND_HANDLER(handle_arm9tdmi_catch_vectors_command)
return ERROR_OK;
}
int arm9tdmi_register_commands(struct command_context_s *cmd_ctx)
int arm9tdmi_register_commands(struct command_context *cmd_ctx)
{
int retval;
command_t *arm9tdmi_cmd;
+2 -2
View File
@@ -51,12 +51,12 @@ enum arm9tdmi_vector_bit
ARM9TDMI_FIQ_VECTOR = 0x80,
};
int arm9tdmi_init_target(struct command_context_s *cmd_ctx,
int arm9tdmi_init_target(struct command_context *cmd_ctx,
struct target *target);
int arm9tdmi_examine(struct target *target);
int arm9tdmi_init_arch_info(struct target *target,
struct arm9tdmi_common *arm9tdmi, struct jtag_tap *tap);
int arm9tdmi_register_commands(struct command_context_s *cmd_ctx);
int arm9tdmi_register_commands(struct command_context *cmd_ctx);
int arm9tdmi_clock_out(struct arm_jtag *jtag_info,
uint32_t instr, uint32_t out, uint32_t *in, int sysspeed);
+1 -1
View File
@@ -1022,7 +1022,7 @@ is_dap_cid_ok(uint32_t cid3, uint32_t cid2, uint32_t cid1, uint32_t cid0)
&& ((cid1 & 0x0f) == 0) && cid0 == 0x0d;
}
int dap_info_command(struct command_context_s *cmd_ctx, struct swjdp_common *swjdp, int apsel)
int dap_info_command(struct command_context *cmd_ctx, struct swjdp_common *swjdp, int apsel)
{
uint32_t dbgbase,apid;
+1 -1
View File
@@ -156,7 +156,7 @@ int ahbap_debugport_init(struct swjdp_common *swjdp);
/* Commands for user dap access */
int dap_info_command(struct command_context_s *cmd_ctx,
int dap_info_command(struct command_context *cmd_ctx,
struct swjdp_common *swjdp, int apsel);
#define DAP_COMMAND_HANDLER(name) \
+1 -1
View File
@@ -462,7 +462,7 @@ usage:
return ERROR_OK;
}
int armv4_5_register_commands(struct command_context_s *cmd_ctx)
int armv4_5_register_commands(struct command_context *cmd_ctx)
{
command_t *armv4_5_cmd;
+1 -1
View File
@@ -179,7 +179,7 @@ int armv4_5_arch_state(struct target *target);
int armv4_5_get_gdb_reg_list(struct target *target,
struct reg **reg_list[], int *reg_list_size);
int armv4_5_register_commands(struct command_context_s *cmd_ctx);
int armv4_5_register_commands(struct command_context *cmd_ctx);
int armv4_5_init_arch_info(struct target *target, struct arm *armv4_5);
int armv4_5_run_algorithm(struct target *target,
+1 -1
View File
@@ -87,7 +87,7 @@ int armv4_5_identify_cache(uint32_t cache_type_reg, struct armv4_5_cache_common
return ERROR_OK;
}
int armv4_5_handle_cache_info_command(struct command_context_s *cmd_ctx, struct armv4_5_cache_common *armv4_5_cache)
int armv4_5_handle_cache_info_command(struct command_context *cmd_ctx, struct armv4_5_cache_common *armv4_5_cache)
{
if (armv4_5_cache->ctype == -1)
{
+2 -2
View File
@@ -22,7 +22,7 @@
#include "types.h"
struct command_context_s;
struct command_context;
struct armv4_5_cachesize
{
@@ -47,7 +47,7 @@ int armv4_5_identify_cache(uint32_t cache_type_reg,
int armv4_5_cache_state(uint32_t cp15_control_reg,
struct armv4_5_cache_common *cache);
int armv4_5_handle_cache_info_command(struct command_context_s *cmd_ctx,
int armv4_5_handle_cache_info_command(struct command_context *cmd_ctx,
struct armv4_5_cache_common *armv4_5_cache);
enum
+1 -1
View File
@@ -361,7 +361,7 @@ usage:
return ERROR_OK;
}
int armv7a_register_commands(struct command_context_s *cmd_ctx)
int armv7a_register_commands(struct command_context *cmd_ctx)
{
command_t *arm_adi_v5_dap_cmd;
command_t *armv7a_cmd;
+1 -1
View File
@@ -152,7 +152,7 @@ struct armv7a_core_reg
int armv7a_arch_state(struct target *target);
struct reg_cache *armv7a_build_reg_cache(struct target *target,
struct armv7a_common *armv7a_common);
int armv7a_register_commands(struct command_context_s *cmd_ctx);
int armv7a_register_commands(struct command_context *cmd_ctx);
int armv7a_init_arch_info(struct target *target, struct armv7a_common *armv7a);
/* map psr mode bits to linear number */
+1 -1
View File
@@ -832,7 +832,7 @@ COMMAND_HANDLER(handle_dap_info_command)
}
/** Registers commands used to access DAP resources. */
int armv7m_register_commands(struct command_context_s *cmd_ctx)
int armv7m_register_commands(struct command_context *cmd_ctx)
{
command_t *arm_adi_v5_dap_cmd;
+1 -1
View File
@@ -142,7 +142,7 @@ int armv7m_arch_state(struct target *target);
int armv7m_get_gdb_reg_list(struct target *target,
struct reg **reg_list[], int *reg_list_size);
int armv7m_register_commands(struct command_context_s *cmd_ctx);
int armv7m_register_commands(struct command_context *cmd_ctx);
int armv7m_init_arch_info(struct target *target, struct armv7m_common *armv7m);
int armv7m_run_algorithm(struct target *target,
+4 -4
View File
@@ -29,11 +29,11 @@
#define AVR_JTAG_INS_LEN 4
/* cli handling */
int avr_register_commands(struct command_context_s *cmd_ctx);
int avr_register_commands(struct command_context *cmd_ctx);
/* forward declarations */
int avr_target_create(struct target *target, Jim_Interp *interp);
int avr_init_target(struct command_context_s *cmd_ctx, struct target *target);
int avr_init_target(struct command_context *cmd_ctx, struct target *target);
int avr_arch_state(struct target *target);
int avr_poll(struct target *target);
@@ -96,7 +96,7 @@ struct target_type avr_target =
.init_target = avr_init_target,
};
int avr_register_commands(struct command_context_s *cmd_ctx)
int avr_register_commands(struct command_context *cmd_ctx)
{
LOG_DEBUG("%s", __FUNCTION__);
return ERROR_OK;
@@ -112,7 +112,7 @@ int avr_target_create(struct target *target, Jim_Interp *interp)
return ERROR_OK;
}
int avr_init_target(struct command_context_s *cmd_ctx, struct target *target)
int avr_init_target(struct command_context *cmd_ctx, struct target *target)
{
LOG_DEBUG("%s", __FUNCTION__);
return ERROR_OK;
+2 -2
View File
@@ -1443,7 +1443,7 @@ static void cortex_a8_build_reg_cache(struct target *target)
}
static int cortex_a8_init_target(struct command_context_s *cmd_ctx,
static int cortex_a8_init_target(struct command_context *cmd_ctx,
struct target *target)
{
cortex_a8_build_reg_cache(target);
@@ -1546,7 +1546,7 @@ COMMAND_HANDLER(cortex_a8_handle_dbginit_command)
}
static int cortex_a8_register_commands(struct command_context_s *cmd_ctx)
static int cortex_a8_register_commands(struct command_context *cmd_ctx)
{
command_t *cortex_a8_cmd;
int retval = ERROR_OK;
+3 -3
View File
@@ -1435,7 +1435,7 @@ static int cortex_m3_bulk_write_memory(struct target *target, uint32_t address,
return cortex_m3_write_memory(target, address, 4, count, buffer);
}
static int cortex_m3_init_target(struct command_context_s *cmd_ctx,
static int cortex_m3_init_target(struct command_context *cmd_ctx,
struct target *target)
{
armv7m_build_reg_cache(target);
@@ -1759,7 +1759,7 @@ static int cortex_m3_target_create(struct target *target, Jim_Interp *interp)
/*--------------------------------------------------------------------------*/
static int cortex_m3_verify_pointer(struct command_context_s *cmd_ctx,
static int cortex_m3_verify_pointer(struct command_context *cmd_ctx,
struct cortex_m3_common *cm3)
{
if (cm3->common_magic != CORTEX_M3_COMMON_MAGIC) {
@@ -1928,7 +1928,7 @@ COMMAND_HANDLER(handle_cortex_m3_mask_interrupts_command)
return ERROR_OK;
}
static int cortex_m3_register_commands(struct command_context_s *cmd_ctx)
static int cortex_m3_register_commands(struct command_context *cmd_ctx)
{
int retval;
command_t *cortex_m3_cmd;
+1 -1
View File
@@ -403,7 +403,7 @@ COMMAND_HANDLER(handle_etb_config_command)
return ERROR_OK;
}
static int etb_register_commands(struct command_context_s *cmd_ctx)
static int etb_register_commands(struct command_context *cmd_ctx)
{
command_t *etb_cmd = register_command(cmd_ctx, NULL, "etb",
NULL, COMMAND_ANY, "Embedded Trace Buffer");
+4 -4
View File
@@ -219,7 +219,7 @@ static int etm_reg_arch_type = -1;
static int etm_get_reg(struct reg *reg);
static int etm_read_reg_w_check(struct reg *reg,
uint8_t* check_value, uint8_t* check_mask);
static int etm_register_user_commands(struct command_context_s *cmd_ctx);
static int etm_register_user_commands(struct command_context *cmd_ctx);
static int etm_set_reg_w_exec(struct reg *reg, uint8_t *buf);
static int etm_write_reg(struct reg *reg, uint32_t value);
@@ -884,7 +884,7 @@ static int etmv1_data(struct etm_context *ctx, int size, uint32_t *data)
return 0;
}
static int etmv1_analyze_trace(struct etm_context *ctx, struct command_context_s *cmd_ctx)
static int etmv1_analyze_trace(struct etm_context *ctx, struct command_context *cmd_ctx)
{
int retval;
struct arm_instruction instruction;
@@ -2109,7 +2109,7 @@ COMMAND_HANDLER(handle_etm_analyze_command)
return retval;
}
int etm_register_commands(struct command_context_s *cmd_ctx)
int etm_register_commands(struct command_context *cmd_ctx)
{
etm_cmd = register_command(cmd_ctx, NULL, "etm", NULL, COMMAND_ANY, "Embedded Trace Macrocell");
@@ -2119,7 +2119,7 @@ int etm_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
static int etm_register_user_commands(struct command_context_s *cmd_ctx)
static int etm_register_user_commands(struct command_context *cmd_ctx)
{
register_command(cmd_ctx, etm_cmd, "tracemode", handle_etm_tracemode_command,
COMMAND_EXEC, "configure/display trace mode: "
+2 -2
View File
@@ -126,7 +126,7 @@ struct etm_context;
struct etm_capture_driver
{
char *name;
int (*register_commands)(struct command_context_s *cmd_ctx);
int (*register_commands)(struct command_context *cmd_ctx);
int (*init)(struct etm_context *etm_ctx);
trace_status_t (*status)(struct etm_context *etm_ctx);
int (*read_trace)(struct etm_context *etm_ctx);
@@ -212,7 +212,7 @@ struct reg_cache* etm_build_reg_cache(struct target *target,
int etm_setup(struct target *target);
int etm_register_commands(struct command_context_s *cmd_ctx);
int etm_register_commands(struct command_context *cmd_ctx);
#define ERROR_ETM_INVALID_DRIVER (-1300)
#define ERROR_ETM_PORTMODE_NOT_SUPPORTED (-1301)
+1 -1
View File
@@ -58,7 +58,7 @@ COMMAND_HANDLER(handle_etm_dummy_config_command)
return ERROR_OK;
}
static int etm_dummy_register_commands(struct command_context_s *cmd_ctx)
static int etm_dummy_register_commands(struct command_context *cmd_ctx)
{
command_t *etm_dummy_cmd;
+1 -1
View File
@@ -577,7 +577,7 @@ int feroceon_bulk_write_memory(struct target *target, uint32_t address, uint32_t
return retval;
}
int feroceon_init_target(struct command_context_s *cmd_ctx, struct target *target)
int feroceon_init_target(struct command_context *cmd_ctx, struct target *target)
{
arm9tdmi_init_target(cmd_ctx, target);
return ERROR_OK;
+1 -1
View File
@@ -331,7 +331,7 @@ int mips32_init_arch_info(struct target *target, struct mips32_common *mips32, s
return ERROR_OK;
}
int mips32_register_commands(struct command_context_s *cmd_ctx)
int mips32_register_commands(struct command_context *cmd_ctx)
{
return ERROR_OK;
}
+1 -1
View File
@@ -146,7 +146,7 @@ int mips32_enable_interrupts(struct target *target, int enable);
int mips32_examine(struct target *target);
int mips32_register_commands(struct command_context_s *cmd_ctx);
int mips32_register_commands(struct command_context *cmd_ctx);
int mips32_invalidate_core_regs(struct target *target);
int mips32_get_gdb_reg_list(struct target *target,
+4 -4
View File
@@ -39,8 +39,8 @@ int mips_m4k_resume(struct target *target, int current, uint32_t address, int ha
int mips_m4k_step(struct target *target, int current, uint32_t address, int handle_breakpoints);
int mips_m4k_read_memory(struct target *target, uint32_t address, uint32_t size, uint32_t count, uint8_t *buffer);
int mips_m4k_write_memory(struct target *target, uint32_t address, uint32_t size, uint32_t count, uint8_t *buffer);
int mips_m4k_register_commands(struct command_context_s *cmd_ctx);
int mips_m4k_init_target(struct command_context_s *cmd_ctx, struct target *target);
int mips_m4k_register_commands(struct command_context *cmd_ctx);
int mips_m4k_init_target(struct command_context *cmd_ctx, struct target *target);
int mips_m4k_target_create(struct target *target, Jim_Interp *interp);
int mips_m4k_examine(struct target *target);
@@ -902,7 +902,7 @@ int mips_m4k_write_memory(struct target *target, uint32_t address, uint32_t size
return mips32_dmaacc_write_mem(ejtag_info, address, size, count, (void *)buffer);
}
int mips_m4k_register_commands(struct command_context_s *cmd_ctx)
int mips_m4k_register_commands(struct command_context *cmd_ctx)
{
int retval;
@@ -910,7 +910,7 @@ int mips_m4k_register_commands(struct command_context_s *cmd_ctx)
return retval;
}
int mips_m4k_init_target(struct command_context_s *cmd_ctx, struct target *target)
int mips_m4k_init_target(struct command_context *cmd_ctx, struct target *target)
{
mips32_build_reg_cache(target);
+2 -2
View File
@@ -30,7 +30,7 @@
*/
static int oocd_trace_register_commands(struct command_context_s *cmd_ctx);
static int oocd_trace_register_commands(struct command_context *cmd_ctx);
static int oocd_trace_read_reg(struct oocd_trace *oocd_trace, int reg, uint32_t *value)
{
@@ -407,7 +407,7 @@ COMMAND_HANDLER(handle_oocd_trace_resync_command)
return ERROR_OK;
}
int oocd_trace_register_commands(struct command_context_s *cmd_ctx)
int oocd_trace_register_commands(struct command_context *cmd_ctx)
{
command_t *oocd_trace_cmd;
+14 -14
View File
@@ -336,7 +336,7 @@ static struct target *get_target_by_num(int num)
return NULL;
}
struct target* get_current_target(command_context_t *cmd_ctx)
struct target* get_current_target(struct command_context *cmd_ctx)
{
struct target *target = get_target_by_num(cmd_ctx->current_target);
@@ -425,7 +425,7 @@ int target_resume(struct target *target, int current, uint32_t address, int hand
return retval;
}
int target_process_reset(struct command_context_s *cmd_ctx, enum target_reset_mode reset_mode)
int target_process_reset(struct command_context *cmd_ctx, enum target_reset_mode reset_mode)
{
char buf[100];
int retval;
@@ -754,7 +754,7 @@ err_write_phys_memory(struct target *target, uint32_t address,
return ERROR_FAIL;
}
int target_init(struct command_context_s *cmd_ctx)
int target_init(struct command_context *cmd_ctx)
{
struct target *target;
int retval;
@@ -2201,7 +2201,7 @@ COMMAND_HANDLER(handle_step_command)
return target->type->step(target, current_pc, addr, 1);
}
static void handle_md_output(struct command_context_s *cmd_ctx,
static void handle_md_output(struct command_context *cmd_ctx,
struct target *target, uint32_t address, unsigned size,
unsigned count, const uint8_t *buffer)
{
@@ -2709,7 +2709,7 @@ COMMAND_HANDLER(handle_test_image_command)
return CALL_COMMAND_HANDLER(handle_verify_image_command_internal, 0);
}
static int handle_bp_command_list(struct command_context_s *cmd_ctx)
static int handle_bp_command_list(struct command_context *cmd_ctx)
{
struct target *target = get_current_target(cmd_ctx);
struct breakpoint *breakpoint = target->breakpoints;
@@ -2737,7 +2737,7 @@ static int handle_bp_command_list(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
static int handle_bp_command_set(struct command_context_s *cmd_ctx,
static int handle_bp_command_set(struct command_context *cmd_ctx,
uint32_t addr, uint32_t length, int hw)
{
struct target *target = get_current_target(cmd_ctx);
@@ -3132,7 +3132,7 @@ static int new_int_array_element(Jim_Interp * interp, const char *varname, int i
static int jim_mem2array(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
{
command_context_t *context;
struct command_context *context;
struct target *target;
context = Jim_GetAssocData(interp, "context");
@@ -3321,7 +3321,7 @@ static int get_int_array_element(Jim_Interp * interp, const char *varname, int i
static int jim_array2mem(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
{
command_context_t *context;
struct command_context *context;
struct target *target;
context = Jim_GetAssocData(interp, "context");
@@ -3822,7 +3822,7 @@ static int tcl_target_func(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
uint8_t target_buf[32];
Jim_Nvp *n;
struct target *target;
struct command_context_s *cmd_ctx;
struct command_context *cmd_ctx;
int e;
enum {
@@ -4238,7 +4238,7 @@ static int target_create(Jim_GetOptInfo *goi)
int e;
int x;
struct target *target;
struct command_context_s *cmd_ctx;
struct command_context *cmd_ctx;
cmd_ctx = Jim_GetAssocData(goi->interp, "context");
if (goi->argc < 3) {
@@ -4390,7 +4390,7 @@ static int jim_target(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
{
int x,r,e;
jim_wide w;
struct command_context_s *cmd_ctx;
struct command_context *cmd_ctx;
struct target *target;
Jim_GetOptInfo goi;
enum tcmd {
@@ -4679,7 +4679,7 @@ COMMAND_HANDLER(handle_fast_load_command)
static int jim_mcrmrc(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
{
command_context_t *context;
struct command_context *context;
struct target *target;
int retval;
@@ -4763,7 +4763,7 @@ static int jim_mcrmrc(Jim_Interp *interp, int argc, Jim_Obj *const *argv)
return JIM_OK;
}
int target_register_commands(struct command_context_s *cmd_ctx)
int target_register_commands(struct command_context *cmd_ctx)
{
register_command(cmd_ctx, NULL, "targets",
@@ -4776,7 +4776,7 @@ int target_register_commands(struct command_context_s *cmd_ctx)
return ERROR_OK;
}
int target_register_user_commands(struct command_context_s *cmd_ctx)
int target_register_user_commands(struct command_context *cmd_ctx)
{
int retval = ERROR_OK;
if ((retval = target_request_register_commands(cmd_ctx)) != ERROR_OK)
+6 -6
View File
@@ -34,7 +34,7 @@
struct reg;
struct trace;
struct command_context_s;
struct command_context;
/**
@@ -241,12 +241,12 @@ struct target_timer_callback
struct target_timer_callback *next;
};
int target_register_commands(struct command_context_s *cmd_ctx);
int target_register_user_commands(struct command_context_s *cmd_ctx);
int target_init(struct command_context_s *cmd_ctx);
int target_register_commands(struct command_context *cmd_ctx);
int target_register_user_commands(struct command_context *cmd_ctx);
int target_init(struct command_context *cmd_ctx);
int target_examine(void);
int handle_target(void *priv);
int target_process_reset(struct command_context_s *cmd_ctx,
int target_process_reset(struct command_context *cmd_ctx,
enum target_reset_mode reset_mode);
int target_register_event_callback(
@@ -278,7 +278,7 @@ int target_call_timer_callbacks(void);
*/
int target_call_timer_callbacks_now(void);
struct target* get_current_target(struct command_context_s *cmd_ctx);
struct target* get_current_target(struct command_context *cmd_ctx);
struct target *get_target(const char *id);
/**
+4 -4
View File
@@ -150,7 +150,7 @@ int target_request(struct target *target, uint32_t request)
return ERROR_OK;
}
static int add_debug_msg_receiver(struct command_context_s *cmd_ctx, struct target *target)
static int add_debug_msg_receiver(struct command_context *cmd_ctx, struct target *target)
{
struct debug_msg_receiver **p = &target->dbgmsg;
@@ -178,7 +178,7 @@ static int add_debug_msg_receiver(struct command_context_s *cmd_ctx, struct targ
return ERROR_OK;
}
static struct debug_msg_receiver* find_debug_msg_receiver(struct command_context_s *cmd_ctx, struct target *target)
static struct debug_msg_receiver* find_debug_msg_receiver(struct command_context *cmd_ctx, struct target *target)
{
int do_all_targets = 0;
struct debug_msg_receiver **p = &target->dbgmsg;
@@ -211,7 +211,7 @@ static struct debug_msg_receiver* find_debug_msg_receiver(struct command_context
return NULL;
}
int delete_debug_msg_receiver(struct command_context_s *cmd_ctx, struct target *target)
int delete_debug_msg_receiver(struct command_context *cmd_ctx, struct target *target)
{
struct debug_msg_receiver **p;
struct debug_msg_receiver *c;
@@ -299,7 +299,7 @@ COMMAND_HANDLER(handle_target_request_debugmsgs_command)
return ERROR_OK;
}
int target_request_register_commands(struct command_context_s *cmd_ctx)
int target_request_register_commands(struct command_context *cmd_ctx)
{
target_request_cmd =
register_command(cmd_ctx, NULL, "target_request", NULL, COMMAND_ANY, "target_request commands");
+3 -3
View File
@@ -38,13 +38,13 @@ typedef enum target_req_cmd
struct debug_msg_receiver
{
command_context_t *cmd_ctx;
struct command_context *cmd_ctx;
struct debug_msg_receiver *next;
};
int target_request(struct target *target, uint32_t request);
int delete_debug_msg_receiver(struct command_context_s *cmd_ctx,
int delete_debug_msg_receiver(struct command_context *cmd_ctx,
struct target *target);
int target_request_register_commands(struct command_context_s *cmd_ctx);
int target_request_register_commands(struct command_context *cmd_ctx);
#endif /* TARGET_REQUEST_H */
+2 -2
View File
@@ -151,7 +151,7 @@ struct target_type
*/
int (*run_algorithm)(struct target *target, int num_mem_params, struct mem_param *mem_params, int num_reg_params, struct reg_param *reg_param, uint32_t entry_point, uint32_t exit_point, int timeout_ms, void *arch_info);
int (*register_commands)(struct command_context_s *cmd_ctx);
int (*register_commands)(struct command_context *cmd_ctx);
/* called when target is created */
int (*target_create)(struct target *target, Jim_Interp *interp);
@@ -177,7 +177,7 @@ struct target_type
* It is illegal to talk to the target at this stage as this fn is invoked
* before the JTAG chain has been examined/verified
* */
int (*init_target)(struct command_context_s *cmd_ctx, struct target *target);
int (*init_target)(struct command_context *cmd_ctx, struct target *target);
/* translate from virtual to physical address. Default implementation is successful
* no-op(i.e. virtual==physical).
+1 -1
View File
@@ -156,7 +156,7 @@ COMMAND_HANDLER(handle_trace_history_command)
return ERROR_OK;
}
int trace_register_commands(struct command_context_s *cmd_ctx)
int trace_register_commands(struct command_context *cmd_ctx)
{
command_t *trace_cmd =
register_command(cmd_ctx, NULL, "trace", NULL, COMMAND_ANY, "trace commands");
+2 -2
View File
@@ -23,7 +23,7 @@
#include "types.h"
struct target;
struct command_context_s;
struct command_context;
struct trace_point
{
@@ -52,7 +52,7 @@ typedef enum trace_status
} trace_status_t;
int trace_point(struct target *target, uint32_t number);
int trace_register_commands(struct command_context_s *cmd_ctx);
int trace_register_commands(struct command_context *cmd_ctx);
#define ERROR_TRACE_IMAGE_UNAVAILABLE -(1500)
#define ERROR_TRACE_INSTRUCTION_UNAVAILABLE -(1501)
+4 -4
View File
@@ -146,7 +146,7 @@ static int xscale_set_reg_u32(struct reg *reg, uint32_t value)
static const char xscale_not[] = "target is not an XScale";
static int xscale_verify_pointer(struct command_context_s *cmd_ctx,
static int xscale_verify_pointer(struct command_context *cmd_ctx,
struct xscale_common *xscale)
{
if (xscale->common_magic != XSCALE_COMMON_MAGIC) {
@@ -2630,7 +2630,7 @@ static int xscale_branch_address(struct xscale_trace_data *trace_data,
return 0;
}
static int xscale_analyze_trace(struct target *target, command_context_t *cmd_ctx)
static int xscale_analyze_trace(struct target *target, struct command_context *cmd_ctx)
{
struct xscale_common *xscale = target_to_xscale(target);
int next_pc_ok = 0;
@@ -2860,7 +2860,7 @@ static void xscale_build_reg_cache(struct target *target)
xscale->reg_cache = (*cache_p);
}
static int xscale_init_target(struct command_context_s *cmd_ctx,
static int xscale_init_target(struct command_context *cmd_ctx,
struct target *target)
{
xscale_build_reg_cache(target);
@@ -3575,7 +3575,7 @@ COMMAND_HANDLER(xscale_handle_cp15)
return ERROR_OK;
}
static int xscale_register_commands(struct command_context_s *cmd_ctx)
static int xscale_register_commands(struct command_context *cmd_ctx)
{
command_t *xscale_cmd;