X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Ftarget%2Ftarget_type.h;h=234cdfb0071fce12e8885cd2eff2467a4a83997b;hb=7660c15f02c5a9cf4ac350457283dea0740b9317;hp=21439b656aa396dff6db63ba18e207dfd6dc2c57;hpb=0a4c8990c29e61fd0c2796486519cdb256b8da3b;p=openocd.git diff --git a/src/target/target_type.h b/src/target/target_type.h index 21439b656a..234cdfb007 100644 --- a/src/target/target_type.h +++ b/src/target/target_type.h @@ -130,14 +130,6 @@ struct target_type { int (*write_buffer)(struct target *target, uint32_t address, uint32_t size, const uint8_t *buffer); - /** - * Write target memory in multiples of 4 bytes, optimized for - * writing large quantities of data. Do @b not call this - * function directly, use target_bulk_write_memory() instead. - */ - int (*bulk_write_memory)(struct target *target, uint32_t address, - uint32_t count, const uint8_t *buffer); - int (*checksum_memory)(struct target *target, uint32_t address, uint32_t count, uint32_t *checksum); int (*blank_check_memory)(struct target *target, uint32_t address, @@ -233,6 +225,13 @@ struct target_type { * */ int (*init_target)(struct command_context *cmd_ctx, struct target *target); + /** + * Free all the resources allocated by the target. + * + * @param target The target to deinit + */ + void (*deinit_target)(struct target *target); + /* translate from virtual to physical address. Default implementation is successful * no-op(i.e. virtual==physical). */ @@ -273,6 +272,10 @@ struct target_type { */ int (*gdb_fileio_end)(struct target *target, int retcode, int fileio_errno, bool ctrl_c); + /* do target profiling + */ + int (*profiling)(struct target *target, uint32_t *samples, + uint32_t max_num_samples, uint32_t *num_samples, uint32_t seconds); }; #endif /* TARGET_TYPE_H */