summaryrefslogtreecommitdiff
path: root/src/target/arm7_9_common.c
diff options
context:
space:
mode:
authorØyvind Harboe <oyvind.harboe@zylin.com>2010-07-19 12:34:54 +0200
committerØyvind Harboe <oyvind.harboe@zylin.com>2010-07-19 22:13:49 +0200
commit44ef0327dd97c1893afc63cd7fd8025cb1b57827 (patch)
tree1801b2330958dbfffea61eb2c8cfff033682761a /src/target/arm7_9_common.c
parent6c573df11d1c1bc76c897d0688adfd00ec56ca8e (diff)
downloadopenocd_libswd-44ef0327dd97c1893afc63cd7fd8025cb1b57827.tar.gz
openocd_libswd-44ef0327dd97c1893afc63cd7fd8025cb1b57827.tar.bz2
openocd_libswd-44ef0327dd97c1893afc63cd7fd8025cb1b57827.tar.xz
openocd_libswd-44ef0327dd97c1893afc63cd7fd8025cb1b57827.zip
debug: debug entry error propagation
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
Diffstat (limited to 'src/target/arm7_9_common.c')
-rw-r--r--src/target/arm7_9_common.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/target/arm7_9_common.c b/src/target/arm7_9_common.c
index abe0c2f1..b742daeb 100644
--- a/src/target/arm7_9_common.c
+++ b/src/target/arm7_9_common.c
@@ -1470,7 +1470,11 @@ static int arm7_9_debug_entry(struct target *target)
return retval;
if (arm7_9->post_debug_entry)
- arm7_9->post_debug_entry(target);
+ {
+ retval = arm7_9->post_debug_entry(target);
+ if (retval != ERROR_OK)
+ return retval;
+ }
return ERROR_OK;
}
@@ -1878,7 +1882,9 @@ int arm7_9_resume(struct target *target, int current, uint32_t address, int hand
return err;
}
- arm7_9_debug_entry(target);
+ retval = arm7_9_debug_entry(target);
+ if (retval != ERROR_OK)
+ return retval;
LOG_DEBUG("new PC after step: 0x%8.8" PRIx32,
buf_get_u32(armv4_5->pc->value, 0, 32));
@@ -2079,7 +2085,9 @@ int arm7_9_step(struct target *target, int current, uint32_t address, int handle
{
target->state = TARGET_UNKNOWN;
} else {
- arm7_9_debug_entry(target);
+ retval = arm7_9_debug_entry(target);
+ if (retval != ERROR_OK)
+ return retval;
if ((retval = target_call_event_callbacks(target, TARGET_EVENT_HALTED)) != ERROR_OK)
{
return retval;