X-Git-Url: https://review.openocd.org/gitweb?p=openocd.git;a=blobdiff_plain;f=src%2Ftarget%2Ftarget.h;fp=src%2Ftarget%2Ftarget.h;h=6ef8f10e0719396b027cd2f50edd9e9a0b41c3d0;hp=99ec2be104b178a49fa08a241775045fa77ee04f;hb=f735faa9319af324b94e4257444419c8dfec6592;hpb=35f284fe7c51d29768156cfec172152d2539d98a diff --git a/src/target/target.h b/src/target/target.h index 99ec2be104..6ef8f10e07 100644 --- a/src/target/target.h +++ b/src/target/target.h @@ -726,6 +726,13 @@ int target_alloc_working_area(struct target *target, */ int target_alloc_working_area_try(struct target *target, uint32_t size, struct working_area **area); +/** + * Free a working area. + * Restore target data if area backup is configured. + * @param target + * @param area Pointer to the area to be freed or NULL + * @returns ERROR_OK if successful; error code if restore failed + */ int target_free_working_area(struct target *target, struct working_area *area); void target_free_all_working_areas(struct target *target); uint32_t target_get_working_area_avail(struct target *target);