diff options
author | Øyvind Harboe <oyvind.harboe@zylin.com> | 2010-07-20 08:23:59 +0200 |
---|---|---|
committer | Øyvind Harboe <oyvind.harboe@zylin.com> | 2010-07-20 08:24:53 +0200 |
commit | e0525cd182aee35549f13e786143ccc0a252aeab (patch) | |
tree | 51f6cb173c4299e2d95f757396c8a0f0918162fa /src/target/etm.c | |
parent | a9761c90931101d280b9443126db017f96d92e3d (diff) | |
download | openocd+libswd-e0525cd182aee35549f13e786143ccc0a252aeab.tar.gz openocd+libswd-e0525cd182aee35549f13e786143ccc0a252aeab.tar.bz2 openocd+libswd-e0525cd182aee35549f13e786143ccc0a252aeab.tar.xz openocd+libswd-e0525cd182aee35549f13e786143ccc0a252aeab.zip |
arm_jtag_scann error propagation fixes
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
Diffstat (limited to 'src/target/etm.c')
-rw-r--r-- | src/target/etm.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/target/etm.c b/src/target/etm.c index 5c42fb59..9da69550 100644 --- a/src/target/etm.c +++ b/src/target/etm.c @@ -505,7 +505,9 @@ static int etm_read_reg_w_check(struct reg *reg, LOG_DEBUG("%s (%u)", r->name, reg_addr); - arm_jtag_scann(etm_reg->jtag_info, 0x6, TAP_IDLE); + retval = arm_jtag_scann(etm_reg->jtag_info, 0x6, TAP_IDLE); + if (retval != ERROR_OK) + return retval; retval = arm_jtag_set_instr(etm_reg->jtag_info, etm_reg->jtag_info->intest_instr, NULL, TAP_IDLE); if (retval != ERROR_OK) return retval; @@ -589,7 +591,9 @@ static int etm_write_reg(struct reg *reg, uint32_t value) LOG_DEBUG("%s (%u): 0x%8.8" PRIx32 "", r->name, reg_addr, value); - arm_jtag_scann(etm_reg->jtag_info, 0x6, TAP_IDLE); + retval = arm_jtag_scann(etm_reg->jtag_info, 0x6, TAP_IDLE); + if (retval != ERROR_OK) + return retval; retval = arm_jtag_set_instr(etm_reg->jtag_info, etm_reg->jtag_info->intest_instr, NULL, TAP_IDLE); if (retval != ERROR_OK) return retval; |