aboutsummaryrefslogtreecommitdiff
path: root/src/include/target.h
diff options
context:
space:
mode:
authorGareth McMullin2011-02-21 20:57:56 +1300
committerGareth McMullin2011-02-21 20:57:56 +1300
commit32cabac0f3f2113f04569e8c6201920e30ed8e73 (patch)
treea543db82fe2d0724c591bf3798ff5b390c60af40 /src/include/target.h
parent0dfdc25bb27a6cf56f13a1f9a1c1b233d6aab107 (diff)
Stack is now unwound on hardfault.
Diffstat (limited to 'src/include/target.h')
-rw-r--r--src/include/target.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/include/target.h b/src/include/target.h
index bd32c0f..aa20f39 100644
--- a/src/include/target.h
+++ b/src/include/target.h
@@ -77,6 +77,8 @@
#define target_halt_resume(target, step) \
(target)->halt_resume((target), (step))
+#define target_fault_unwind(target) \
+ ((target)->fault_unwind?(target)->fault_unwind((target)):0)
/* Break-/watchpoint functions */
#define target_set_hw_bp(target, addr) \
@@ -145,6 +147,7 @@ typedef struct target_s {
void (*halt_request)(struct target_s *target);
int (*halt_wait)(struct target_s *target);
void (*halt_resume)(struct target_s *target, uint8_t step);
+ int (*fault_unwind)(struct target_s *target);
/* Break-/watchpoint functions */
int (*set_hw_bp)(struct target_s *target, uint32_t addr);