diff options
author | Antonio Borneo <borneo.antonio@gmail.com> | 2020-08-18 18:56:53 +0200 |
---|---|---|
committer | Antonio Borneo <borneo.antonio@gmail.com> | 2020-09-05 17:12:44 +0100 |
commit | d3249fd45a7832ed922ed4227c867c3c674b4812 (patch) | |
tree | 83bfc6cd029facca6c0a1481cbb66da975fed582 /src/rtos | |
parent | 99add6227fe0a3be536f9b83ff6aa7dd63a8d2dc (diff) | |
download | riscv-openocd-d3249fd45a7832ed922ed4227c867c3c674b4812.zip riscv-openocd-d3249fd45a7832ed922ed4227c867c3c674b4812.tar.gz riscv-openocd-d3249fd45a7832ed922ed4227c867c3c674b4812.tar.bz2 |
openocd: use proper format with uint32_t
Modify the format strings to properly handle uint32_t data types.
Change-Id: I4de49bf02c9e37b72240224c23fc83abe8a4fa83
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5819
Tested-by: jenkins
Diffstat (limited to 'src/rtos')
-rw-r--r-- | src/rtos/ThreadX.c | 2 | ||||
-rw-r--r-- | src/rtos/hwthread.c | 2 | ||||
-rw-r--r-- | src/rtos/linux.c | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/src/rtos/ThreadX.c b/src/rtos/ThreadX.c index 9605533..302641b 100644 --- a/src/rtos/ThreadX.c +++ b/src/rtos/ThreadX.c @@ -248,7 +248,7 @@ static const struct rtos_register_stacking *get_stacking_info_arm926ejs(const st LOG_DEBUG(" solicited stack"); return param->stacking_info + 0; } else { - LOG_DEBUG(" interrupt stack: %u", flag); + LOG_DEBUG(" interrupt stack: %" PRIu32, flag); return param->stacking_info + 1; } } diff --git a/src/rtos/hwthread.c b/src/rtos/hwthread.c index 38e42a0..e0789aa 100644 --- a/src/rtos/hwthread.c +++ b/src/rtos/hwthread.c @@ -281,7 +281,7 @@ static int hwthread_get_thread_reg(struct rtos *rtos, int64_t thread_id, struct reg *reg = register_get_by_number(curr->reg_cache, reg_num, true); if (!reg) { - LOG_ERROR("Couldn't find register %d in thread %" PRId64 ".", reg_num, + LOG_ERROR("Couldn't find register %" PRIu32 " in thread %" PRId64 ".", reg_num, thread_id); return ERROR_FAIL; } diff --git a/src/rtos/linux.c b/src/rtos/linux.c index dbbf97b..44e132d 100644 --- a/src/rtos/linux.c +++ b/src/rtos/linux.c @@ -1483,13 +1483,13 @@ static char *linux_ps_command(struct target *target) if (temp->context) tmp += sprintf(tmp, - "%" PRId32 "\t\t%" PRId32 "\t\t%" PRIx32 "\t\t%s\n", + "%" PRIu32 "\t\t%" PRIu32 "\t\t%" PRIx32 "\t\t%s\n", temp->pid, temp->oncpu, temp->asid, temp->name); else tmp += sprintf(tmp, - "%" PRId32 "\t\t%" PRId32 "\t\t%" PRIx32 "\t\t%s\n", + "%" PRIu32 "\t\t%" PRIu32 "\t\t%" PRIx32 "\t\t%s\n", temp->pid, temp->oncpu, temp->asid, temp->name); } |