aboutsummaryrefslogtreecommitdiff
path: root/AT91SAM7S256/armdebug/Debugger/debug_stub.S
diff options
context:
space:
mode:
authorTat-Chee Wan (USM)2011-03-15 09:51:06 +0800
committerTat-Chee Wan (USM)2011-03-15 09:51:06 +0800
commit5ec6b212c148b98996eba98b4d3ce42ff9ec44fc (patch)
tree1c8602bc8c73b0d5174586a3038ead08b854c320 /AT91SAM7S256/armdebug/Debugger/debug_stub.S
parent00a0b7a3fffa6664d1a71b6feec795d50cbffb44 (diff)
parentcb04001b90e3466ac8770ce596c16dfc49846618 (diff)
Merge branch 'master' of ssh://svc.cs.usm.my/~/gitrepo-bare/armdebug
Diffstat (limited to 'AT91SAM7S256/armdebug/Debugger/debug_stub.S')
-rw-r--r--AT91SAM7S256/armdebug/Debugger/debug_stub.S5
1 files changed, 2 insertions, 3 deletions
diff --git a/AT91SAM7S256/armdebug/Debugger/debug_stub.S b/AT91SAM7S256/armdebug/Debugger/debug_stub.S
index f40b6fb..b020a09 100644
--- a/AT91SAM7S256/armdebug/Debugger/debug_stub.S
+++ b/AT91SAM7S256/armdebug/Debugger/debug_stub.S
@@ -533,14 +533,13 @@ dbg__bkpt_offset_outofrange:
*
****************************************************************************/
dbg__bkpt_waitCMD:
- bl dbg__getDebugMsg /* Read new message from Debugger, message buffer length in R0, 0 if none, -1 if error */
+ bl dbg__getDebugMsg /* Read new message from Debugger, buflen in R0, 0 if none, -1 if error, msgbuf pointer in R1 */
cmp r0, #0
beq _dbg__housekeeping /* No message yet, do housekeeping tasks */
movlt r0, #MSG_ERRCHKSUM /* Message invalid, checksum error? */
blt _dbg__cmdError /* Send response to GDB server */
/* Message now has $<packet info>\0 */
- ldr r4, =debug_msgRxBufPtr
- ldr r4, [r4] /* Rx buffer Start Address */
+ mov r4, r1 /* Use R4 as buffer pointer */
ldrb r0, [r4], #1 /* Look for '$' */
teq r0, #MSGBUF_STARTCHAR
movne r0, #MSG_ERRFORMAT /* Message Format invalid (not '$') */