diff options
author | Andreas Fritiofson <andreas.fritiofson@gmail.com> | 2011-07-15 22:18:39 +0200 |
---|---|---|
committer | Andreas Fritiofson <andreas.fritiofson@gmail.com> | 2011-10-09 00:00:52 +0200 |
commit | 3f6ef7a40bcff5e1278b662248902c45a1dc8f81 (patch) | |
tree | cf3a506ae661ceb9fb4b83ee154e97ba70ac9ac8 /src/target/target_type.h | |
parent | e56e5a3929a05d18e560c8e37f1985aeb4b95cc9 (diff) |
target: add async algorithm entries to the target type
On supported targets, this may be used to start a long running algorithm in
the background so the target may be interacted with during execution and
later wait for its completion.
The most obvious use case is a double buffered flash algorithm that can
upload the next block of data while the algorithm is flashing the current.
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Diffstat (limited to 'src/target/target_type.h')
-rw-r--r-- | src/target/target_type.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/target/target_type.h b/src/target/target_type.h index fc062dab..10b6f33a 100644 --- a/src/target/target_type.h +++ b/src/target/target_type.h @@ -171,6 +171,8 @@ struct target_type * use target_run_algorithm() instead. */ 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 (*start_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, void *arch_info); + int (*wait_algorithm)(struct target *target, int num_mem_params, struct mem_param *mem_params, int num_reg_params, struct reg_param *reg_param, uint32_t exit_point, int timeout_ms, void *arch_info); const struct command_registration *commands; |