X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Frtos%2Frtos.c;h=3420d06b7520b919113f0f67340f6ffa98de8915;hb=528197ba2cf2b208efa4d5c8465a9044567e8d69;hp=f14e53890c16cb1aa47b9e1e787478ef795c5ffd;hpb=c50047bb418da6a4ed735ca87acee04e7fd2dbe7;p=openocd.git diff --git a/src/rtos/rtos.c b/src/rtos/rtos.c index f14e53890c..3420d06b75 100644 --- a/src/rtos/rtos.c +++ b/src/rtos/rtos.c @@ -406,8 +406,11 @@ int rtos_thread_packet(struct connection *connection, char const *packet, int pa return ERROR_OK; } else if (packet[0] == 'H') { /* Set current thread ( 'c' for step and continue, 'g' for * all other operations ) */ - if ((packet[1] == 'g') && (target->rtos != NULL)) + if ((packet[1] == 'g') && (target->rtos != NULL)) { sscanf(packet, "Hg%16" SCNx64, &target->rtos->current_threadid); + LOG_DEBUG("RTOS: GDB requested to set current thread to 0x%" PRIx64 "\r\n", + target->rtos->current_threadid); + } gdb_put_packet(connection, "OK", 2); return ERROR_OK; } @@ -424,6 +427,12 @@ int rtos_get_gdb_reg_list(struct connection *connection) ((current_threadid != target->rtos->current_thread) || (target->smp))) { /* in smp several current thread are possible */ char *hex_reg_list; + + LOG_DEBUG("RTOS: getting register list for thread 0x%" PRIx64 + ", target->rtos->current_thread=0x%" PRIx64 "\r\n", + current_threadid, + target->rtos->current_thread); + target->rtos->type->get_thread_reg_list(target->rtos, current_threadid, &hex_reg_list); @@ -464,6 +473,8 @@ int rtos_generic_stack_read(struct target *target, LOG_ERROR("Error reading stack frame from thread"); return retval; } + LOG_DEBUG("RTOS: Read stack frame at 0x%" PRIx32, address); + #if 0 LOG_OUTPUT("Stack Data :"); for (i = 0; i < stacking->stack_registers_size; i++)