summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTat-Chee Wan (USM)2011-06-17 09:12:26 +0800
committerTat-Chee Wan (USM)2011-06-17 09:12:26 +0800
commitad497e188b490981211ecf61edf12a92d32a233b (patch)
treefc5e31d88a937338af01e028edcdb74269107e94
parent517c98db287a2f66ef0df365b4a3c054e9c87cba (diff)
fix return status check for nx_usb_data_written
The C return value for True is not identical to that used by ARMDEBUG. Check for False instead.
-rw-r--r--Debugger/debug_comm.S6
1 files changed, 4 insertions, 2 deletions
diff --git a/Debugger/debug_comm.S b/Debugger/debug_comm.S
index a3600a2..1789cb1 100644
--- a/Debugger/debug_comm.S
+++ b/Debugger/debug_comm.S
@@ -420,9 +420,11 @@ _dbg__sendCommMsg:
bl nx_usb_write
1: bl nx_usb_data_written /* R0 = True if data has been sent */
- cmp r0, #TRUE
+ teq r0, #0 /* FALSE == #0;
+ We can't check for True condition since values
+ used by C-Compiler & ARMDEBUG are different */
/* FIXME: implement timeout */
- bne 1b /* Busy Wait Loop */
+ beq 1b /* Busy Wait Loop */
#else
ldr r0, =debug_nxtCommChannel
ldr r0, [r0] /* Get Channel Enum */