|
From: openocd-gerrit <ope...@us...> - 2023-05-06 13:35:05
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Main OpenOCD repository".
The branch, master has been updated
via 329b10754aa2294d11717c461f356c174eba5094 (commit)
from 92c1bee18c8268511de3478aabd226ce4f92322a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 329b10754aa2294d11717c461f356c174eba5094
Author: Antonio Borneo <bor...@gm...>
Date: Sun Apr 9 01:00:15 2023 +0200
target: etm: fix check trace status
Current code tests a function pointer against a numeric value that
is the same enum type as returned by the pointed function.
Clearly the author was willing to call the function and check its
returned value.
Fix the check by calling the function.
Detected through 'sparse' tool.
Change-Id: I27d18d26c2c797160a397daa32835c199014b70b
Signed-off-by: Antonio Borneo <bor...@gm...>
Checkpatch-ignore: GIT_COMMIT_ID
Fixes: 237e894805dd ("reworked etm/etb into a generic etm part with trace capture")
Reviewed-on: https://review.openocd.org/c/openocd/+/7599
Tested-by: jenkins
Reviewed-by: Tomas Vanek <va...@fb...>
diff --git a/src/target/etm.c b/src/target/etm.c
index 57417c3fa..6718875ee 100644
--- a/src/target/etm.c
+++ b/src/target/etm.c
@@ -1706,7 +1706,7 @@ COMMAND_HANDLER(handle_etm_dump_command)
return ERROR_FAIL;
}
- if (etm_ctx->capture_driver->status == TRACE_IDLE) {
+ if (etm_ctx->capture_driver->status(etm_ctx) == TRACE_IDLE) {
command_print(CMD, "trace capture wasn't enabled, no trace data captured");
return ERROR_OK;
}
-----------------------------------------------------------------------
Summary of changes:
src/target/etm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
hooks/post-receive
--
Main OpenOCD repository
|