From: Øyvind H. <go...@us...> - 2010-06-18 10:03:41
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Main OpenOCD repository". The branch, master has been updated via b8f8d756a255936ccfb60ac3dda076e4e06108a6 (commit) via 2319caff7d9ddf27311a9d592f6d143d71cd5602 (commit) from 3f9d377ce788365844f9225064cb9b0f0b4542ef (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit b8f8d756a255936ccfb60ac3dda076e4e06108a6 Author: Antonio Borneo <bor...@gm...> Date: Fri Jun 18 14:30:26 2010 +0800 target/dsp563xx: review unused symbols Remove unused functions: - dsp563xx_jtag_senddat - dsp563xx_write_ir_u16 - dsp563xx_write_dr_u16 - dsp563xx_write_ir_u32 Signed-off-by: Antonio Borneo <bor...@gm...> diff --git a/src/target/dsp563xx.c b/src/target/dsp563xx.c index 48e559e..a454c76 100644 --- a/src/target/dsp563xx.c +++ b/src/target/dsp563xx.c @@ -51,8 +51,6 @@ static int dsp563xx_write_ir_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t i /* IR and DR functions */ static int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out); -int dsp563xx_jtag_senddat(struct jtag_tap *tap, uint32_t * dr_in, uint32_t dr_out, - int len); #define ASM_REG_R_R0 0x607000 #define ASM_REG_R_R1 0x617000 @@ -819,12 +817,6 @@ static int dsp563xx_write_memory_p(struct target *target, uint32_t address, uint return ERROR_OK; } -int dsp563xx_jtag_senddat(struct jtag_tap *tap, uint32_t * dr_in, uint32_t dr_out, - int len) -{ - return dsp563xx_write_dr_u32(tap, dr_in, dr_out, len, 1); -} - static int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out) { return dsp563xx_write_ir_u8(tap, ir_in, ir_out, DSP563XX_JTAG_INS_LEN, 1); @@ -896,48 +888,6 @@ int dsp563xx_write_dr_u8(struct jtag_tap *tap, uint8_t * dr_in, uint8_t dr_out, return ERROR_OK; } -int dsp563xx_write_ir_u16(struct jtag_tap *tap, uint16_t * ir_in, uint16_t ir_out, - int ir_len, int rti) -{ - if (ir_len > 16) - { - LOG_ERROR("ir_len overflow, maxium is 16"); - return ERROR_FAIL; - } - - dsp563xx_write_ir(tap, (uint8_t *) ir_in, (uint8_t *) & ir_out, ir_len, rti); - - return ERROR_OK; -} - -int dsp563xx_write_dr_u16(struct jtag_tap *tap, uint16_t * dr_in, uint16_t dr_out, - int dr_len, int rti) -{ - if (dr_len > 16) - { - LOG_ERROR("dr_len overflow, maxium is 16"); - return ERROR_FAIL; - } - - dsp563xx_write_dr(tap, (uint8_t *) dr_in, (uint8_t *) & dr_out, dr_len, rti); - - return ERROR_OK; -} - -int dsp563xx_write_ir_u32(struct jtag_tap *tap, uint32_t * ir_in, uint32_t ir_out, - int ir_len, int rti) -{ - if (ir_len > 32) - { - LOG_ERROR("ir_len overflow, maxium is 32"); - return ERROR_FAIL; - } - - dsp563xx_write_ir(tap, (uint8_t *) ir_in, (uint8_t *) & ir_out, ir_len, rti); - - return ERROR_OK; -} - int dsp563xx_write_dr_u32(struct jtag_tap *tap, uint32_t * dr_in, uint32_t dr_out, int dr_len, int rti) { diff --git a/src/target/dsp563xx.h b/src/target/dsp563xx.h index 3258faa..f8070fa 100644 --- a/src/target/dsp563xx.h +++ b/src/target/dsp563xx.h @@ -68,12 +68,6 @@ static inline struct dsp563xx_common *target_to_dsp563xx(struct target *target) int dsp563xx_write_dr_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out, int dr_len, int rti); -int dsp563xx_write_ir_u16(struct jtag_tap *tap, uint16_t * ir_in, uint16_t ir_out, - int ir_len, int rti); -int dsp563xx_write_dr_u16(struct jtag_tap *tap, uint16_t * ir_in, uint16_t ir_out, - int dr_len, int rti); -int dsp563xx_write_ir_u32(struct jtag_tap *tap, uint32_t * ir_in, uint32_t ir_out, - int ir_len, int rti); int dsp563xx_write_dr_u32(struct jtag_tap *tap, uint32_t * ir_in, uint32_t ir_out, int dr_len, int rti); commit 2319caff7d9ddf27311a9d592f6d143d71cd5602 Author: Antonio Borneo <bor...@gm...> Date: Fri Jun 18 14:28:01 2010 +0800 target/dsp563xx: review scope of symbols Add "static" qualifier to private functions. Remove private prototypes from include file. Signed-off-by: Antonio Borneo <bor...@gm...> diff --git a/src/target/dsp563xx.c b/src/target/dsp563xx.c index b42e7b3..48e559e 100644 --- a/src/target/dsp563xx.c +++ b/src/target/dsp563xx.c @@ -46,31 +46,14 @@ #define JTAG_INSTR_BYPASS 0x0F /* forward declarations */ -int dsp563xx_target_create(struct target *target, Jim_Interp * interp); -int dsp563xx_init_target(struct command_context *cmd_ctx, struct target *target); - -int dsp563xx_arch_state(struct target *target); -int dsp563xx_poll(struct target *target); -int dsp563xx_halt(struct target *target); -int dsp563xx_resume(struct target *target, int current, uint32_t address, - int handle_breakpoints, int debug_execution); -int dsp563xx_step(struct target *target, int current, uint32_t address, - int handle_breakpoints); - -int dsp563xx_assert_reset(struct target *target); -int dsp563xx_deassert_reset(struct target *target); -int dsp563xx_soft_reset_halt(struct target *target); +static int dsp563xx_write_ir_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out, + int ir_len, int rti); /* IR and DR functions */ -int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out); +static int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out); int dsp563xx_jtag_senddat(struct jtag_tap *tap, uint32_t * dr_in, uint32_t dr_out, int len); -int dsp563xx_read_memory_p(struct target *target, uint32_t address, uint32_t size, - uint32_t count, uint8_t * buffer); -int dsp563xx_write_memory_p(struct target *target, uint32_t address, uint32_t size, - uint32_t count, uint8_t * buffer); - #define ASM_REG_R_R0 0x607000 #define ASM_REG_R_R1 0x617000 #define ASM_REG_R_R2 0x627000 @@ -269,7 +252,7 @@ static int dsp563xx_get_gdb_reg_list(struct target *target, struct reg **reg_lis } -int dsp563xx_read_core_reg(struct target *target, int num) +static int dsp563xx_read_core_reg(struct target *target, int num) { uint32_t reg_value; struct dsp563xx_core_reg *dsp563xx_core_reg; @@ -287,7 +270,7 @@ int dsp563xx_read_core_reg(struct target *target, int num) return ERROR_OK; } -int dsp563xx_write_core_reg(struct target *target, int num) +static int dsp563xx_write_core_reg(struct target *target, int num) { uint32_t reg_value; struct dsp563xx_core_reg *dsp563xx_core_reg; @@ -305,7 +288,7 @@ int dsp563xx_write_core_reg(struct target *target, int num) return ERROR_OK; } -int dsp563xx_target_create(struct target *target, Jim_Interp * interp) +static int dsp563xx_target_create(struct target *target, Jim_Interp * interp) { struct dsp563xx_common *dsp563xx = calloc(1, sizeof(struct dsp563xx_common)); @@ -317,7 +300,7 @@ int dsp563xx_target_create(struct target *target, Jim_Interp * interp) return ERROR_OK; } -int dsp563xx_get_core_reg(struct reg *reg) +static int dsp563xx_get_core_reg(struct reg *reg) { int retval = 0; @@ -337,7 +320,7 @@ int dsp563xx_get_core_reg(struct reg *reg) return retval; } -int dsp563xx_set_core_reg(struct reg *reg, uint8_t * buf) +static int dsp563xx_set_core_reg(struct reg *reg, uint8_t * buf) { LOG_DEBUG("%s", __FUNCTION__); @@ -357,7 +340,7 @@ int dsp563xx_set_core_reg(struct reg *reg, uint8_t * buf) return ERROR_OK; } -int dsp563xx_save_context(struct target *target) +static int dsp563xx_save_context(struct target *target) { int i; uint32_t data = 0; @@ -388,7 +371,7 @@ int dsp563xx_save_context(struct target *target) return ERROR_OK; } -int dsp563xx_restore_context(struct target *target) +static int dsp563xx_restore_context(struct target *target) { int i; struct dsp563xx_common *dsp563xx = target_to_dsp563xx(target); @@ -416,7 +399,7 @@ static const struct reg_arch_type dsp563xx_reg_type = { .set = dsp563xx_set_core_reg, }; -int dsp563xx_init_target(struct command_context *cmd_ctx, struct target *target) +static int dsp563xx_init_target(struct command_context *cmd_ctx, struct target *target) { /* get pointers to arch-specific information */ struct dsp563xx_common *dsp563xx = target_to_dsp563xx(target); @@ -459,13 +442,13 @@ int dsp563xx_init_target(struct command_context *cmd_ctx, struct target *target) return ERROR_OK; } -int dsp563xx_arch_state(struct target *target) +static int dsp563xx_arch_state(struct target *target) { LOG_DEBUG("%s", __FUNCTION__); return ERROR_OK; } -int dsp563xx_jtag_status(struct target *target, uint8_t * status) +static int dsp563xx_jtag_status(struct target *target, uint8_t * status) { uint8_t ir_in; @@ -479,7 +462,7 @@ int dsp563xx_jtag_status(struct target *target, uint8_t * status) return ERROR_OK; } -int dsp563xx_jtag_debug_request(struct target *target) +static int dsp563xx_jtag_debug_request(struct target *target) { uint8_t ir_in = 0; uint32_t retry = 0; @@ -506,7 +489,7 @@ int dsp563xx_jtag_debug_request(struct target *target) return ERROR_OK; } -int dsp563xx_poll(struct target *target) +static int dsp563xx_poll(struct target *target) { uint8_t jtag_status; uint32_t once_status; @@ -537,7 +520,7 @@ int dsp563xx_poll(struct target *target) return ERROR_OK; } -int dsp563xx_halt(struct target *target) +static int dsp563xx_halt(struct target *target) { uint8_t jtag_status; uint32_t once_status; @@ -582,7 +565,7 @@ int dsp563xx_halt(struct target *target) #define DSP563XX_ASM_CMD_JUMP 0x0AF080 -int dsp563xx_resume(struct target *target, int current, uint32_t address, +static int dsp563xx_resume(struct target *target, int current, uint32_t address, int handle_breakpoints, int debug_execution) { struct dsp563xx_common *dsp563xx = target_to_dsp563xx(target); @@ -616,7 +599,7 @@ int dsp563xx_resume(struct target *target, int current, uint32_t address, return ERROR_OK; } -int dsp563xx_step(struct target *target, int current, uint32_t address, +static int dsp563xx_step(struct target *target, int current, uint32_t address, int handle_breakpoints) { uint32_t once_status; @@ -708,7 +691,7 @@ int dsp563xx_step(struct target *target, int current, uint32_t address, return ERROR_OK; } -int dsp563xx_assert_reset(struct target *target) +static int dsp563xx_assert_reset(struct target *target) { target->state = TARGET_RESET; @@ -716,7 +699,7 @@ int dsp563xx_assert_reset(struct target *target) return ERROR_OK; } -int dsp563xx_deassert_reset(struct target *target) +static int dsp563xx_deassert_reset(struct target *target) { target->state = TARGET_RUNNING; @@ -724,7 +707,7 @@ int dsp563xx_deassert_reset(struct target *target) return ERROR_OK; } -int dsp563xx_soft_reset_halt(struct target *target) +static int dsp563xx_soft_reset_halt(struct target *target) { LOG_DEBUG("%s", __FUNCTION__); return ERROR_OK; @@ -752,7 +735,7 @@ int dsp563xx_soft_reset_halt(struct target *target) * 076190 movem r0,p:(r1) * */ -int dsp563xx_read_memory_p(struct target *target, uint32_t address, +static int dsp563xx_read_memory_p(struct target *target, uint32_t address, uint32_t size, uint32_t count, uint8_t * buffer) { uint32_t i, x; @@ -793,7 +776,7 @@ int dsp563xx_read_memory_p(struct target *target, uint32_t address, return ERROR_OK; } -int dsp563xx_write_memory_p(struct target *target, uint32_t address, uint32_t size, +static int dsp563xx_write_memory_p(struct target *target, uint32_t address, uint32_t size, uint32_t count, uint8_t * buffer) { uint32_t i, x; @@ -842,13 +825,13 @@ int dsp563xx_jtag_senddat(struct jtag_tap *tap, uint32_t * dr_in, uint32_t dr_ou return dsp563xx_write_dr_u32(tap, dr_in, dr_out, len, 1); } -int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out) +static int dsp563xx_jtag_sendinstr(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out) { return dsp563xx_write_ir_u8(tap, ir_in, ir_out, DSP563XX_JTAG_INS_LEN, 1); } /* IR and DR functions */ -int dsp563xx_write_ir(struct jtag_tap *tap, uint8_t * ir_in, uint8_t * ir_out, +static int dsp563xx_write_ir(struct jtag_tap *tap, uint8_t * ir_in, uint8_t * ir_out, int ir_len, int rti) { if (NULL == tap) @@ -869,7 +852,7 @@ int dsp563xx_write_ir(struct jtag_tap *tap, uint8_t * ir_in, uint8_t * ir_out, return ERROR_OK; } -int dsp563xx_write_dr(struct jtag_tap *tap, uint8_t * dr_in, uint8_t * dr_out, +static int dsp563xx_write_dr(struct jtag_tap *tap, uint8_t * dr_in, uint8_t * dr_out, int dr_len, int rti) { if (NULL == tap) @@ -885,7 +868,7 @@ int dsp563xx_write_dr(struct jtag_tap *tap, uint8_t * dr_in, uint8_t * dr_out, return ERROR_OK; } -int dsp563xx_write_ir_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out, +static int dsp563xx_write_ir_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out, int ir_len, int rti) { if (ir_len > 8) diff --git a/src/target/dsp563xx.h b/src/target/dsp563xx.h index 73050b6..3258faa 100644 --- a/src/target/dsp563xx.h +++ b/src/target/dsp563xx.h @@ -66,12 +66,6 @@ static inline struct dsp563xx_common *target_to_dsp563xx(struct target *target) return target->arch_info; } -int dsp563xx_write_ir(struct jtag_tap *tap, uint8_t * ir_in, uint8_t * ir_out, - int ir_len, int rti); -int dsp563xx_write_dr(struct jtag_tap *tap, uint8_t * dr_in, uint8_t * dr_out, - int dr_len, int rti); -int dsp563xx_write_ir_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out, - int ir_len, int rti); int dsp563xx_write_dr_u8(struct jtag_tap *tap, uint8_t * ir_in, uint8_t ir_out, int dr_len, int rti); int dsp563xx_write_ir_u16(struct jtag_tap *tap, uint16_t * ir_in, uint16_t ir_out, ----------------------------------------------------------------------- Summary of changes: src/target/dsp563xx.c | 121 +++++++++++-------------------------------------- src/target/dsp563xx.h | 12 ----- 2 files changed, 27 insertions(+), 106 deletions(-) hooks/post-receive -- Main OpenOCD repository |