Add target_run_algorithm wrapper:

- replaces all calls to target->type->run_algorithm.
- add documentation in target_s to warn not to invoke callback directly.


git-svn-id: svn://svn.berlios.de/openocd/trunk@1961 b42882b7-edfa-0310-969c-e2dbd0fdcd60
This commit is contained in:
zwelch
2009-05-31 09:38:20 +00:00
parent 95e13054ca
commit fbe8cf72a5
14 changed files with 41 additions and 15 deletions

View File

@@ -537,6 +537,17 @@ int target_write_memory(struct target_s *target,
return target->type->write_memory(target, address, size, count, buffer);
}
int target_run_algorithm(struct target_s *target,
int num_mem_params, mem_param_t *mem_params,
int num_reg_params, reg_param_t *reg_param,
u32 entry_point, u32 exit_point,
int timeout_ms, void *arch_info)
{
return target->type->run_algorithm(target,
num_mem_params, mem_params, num_reg_params, reg_param,
entry_point, exit_point, timeout_ms, arch_info);
}
int target_init(struct command_context_s *cmd_ctx)
{