diff options
author | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2008-08-19 16:43:30 +0000 |
---|---|---|
committer | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2008-08-19 16:43:30 +0000 |
commit | d8057f6db1e6a466e53eba7e194130d52093445f (patch) | |
tree | 80de595858525b39c7db0c49fb68dcb463b0928f /src | |
parent | ea0270e38ee811e4a64b9f21b8a71dcc2559626f (diff) | |
download | openocd+libswd-d8057f6db1e6a466e53eba7e194130d52093445f.tar.gz openocd+libswd-d8057f6db1e6a466e53eba7e194130d52093445f.tar.bz2 openocd+libswd-d8057f6db1e6a466e53eba7e194130d52093445f.tar.xz openocd+libswd-d8057f6db1e6a466e53eba7e194130d52093445f.zip |
switch to alive_sleep() to avoid gdb timeouts
git-svn-id: svn://svn.berlios.de/openocd/trunk@945 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src')
-rw-r--r-- | src/target/cortex_m3.c | 2 | ||||
-rw-r--r-- | src/target/cortex_swjdp.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/target/cortex_m3.c b/src/target/cortex_m3.c index 9e0916ff..12574c66 100644 --- a/src/target/cortex_m3.c +++ b/src/target/cortex_m3.c @@ -523,7 +523,7 @@ int cortex_m3_soft_reset_halt(struct target_s *target) LOG_DEBUG("waiting for system reset-halt, dcb_dhcsr 0x%x, %i ms", dcb_dhcsr, timeout); } timeout++; - usleep(1000); + alive_sleep(1); } return ERROR_OK; diff --git a/src/target/cortex_swjdp.c b/src/target/cortex_swjdp.c index dc50fea1..a4a997b8 100644 --- a/src/target/cortex_swjdp.c +++ b/src/target/cortex_swjdp.c @@ -966,7 +966,7 @@ int ahbap_debugport_init(swjdp_common_t *swjdp) swjdp_read_dpacc(swjdp, &ctrlstat, DP_CTRL_STAT); if ((retval=jtag_execute_queue())!=ERROR_OK) return retval; - usleep(10000); + alive_sleep(10); } while (!(ctrlstat & CSYSPWRUPACK) && (cnt++ < 10)) @@ -975,7 +975,7 @@ int ahbap_debugport_init(swjdp_common_t *swjdp) swjdp_read_dpacc(swjdp, &ctrlstat, DP_CTRL_STAT); if ((retval=jtag_execute_queue())!=ERROR_OK) return retval; - usleep(10000); + alive_sleep(10); } swjdp_read_dpacc(swjdp, &dummy, DP_CTRL_STAT); |