|
From: openocd-gerrit <ope...@us...> - 2023-06-16 22:12:38
|
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 eebcf3cff16afbce2c57cf2dba6f562e17713093 (commit)
from 63f4e7c72a27fb828fe1be3003be6a94519e1c12 (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 eebcf3cff16afbce2c57cf2dba6f562e17713093
Author: Marek Vrbka <mar...@co...>
Date: Mon Jun 5 08:35:09 2023 +0200
riscv/semihosting: Fix ebreak skip on fileio mode
This patch fixes skipping the semihosting sequence if
the fileio mode is enabled on riscv. This change was
tested by me and is in the riscv-openocd fork for a year now.
Original merge request:
https://github.com/riscv/riscv-openocd/pull/699
Original author: Wu Zhigang
zhi...@st...
https://github.com/wzgpeter
Change-Id: Iadaa0a48d1f82d3a7ca168f8a6b656ff6ab78e03
Signed-off-by: Marek Vrbka <mar...@co...>
Reviewed-on: https://review.openocd.org/c/openocd/+/7729
Tested-by: jenkins
Reviewed-by: Tim Newsome <ti...@si...>
diff --git a/src/target/riscv/riscv_semihosting.c b/src/target/riscv/riscv_semihosting.c
index 1bc4e1a16..da237ef33 100644
--- a/src/target/riscv/riscv_semihosting.c
+++ b/src/target/riscv/riscv_semihosting.c
@@ -141,16 +141,16 @@ enum semihosting_result riscv_semihosting(struct target *target, int *retval)
}
}
+ /* Resume right after the EBREAK 4 bytes instruction. */
+ *retval = riscv_set_register(target, GDB_REGNO_PC, pc + 4);
+ if (*retval != ERROR_OK)
+ return SEMIHOSTING_ERROR;
+
/*
* Resume target if we are not waiting on a fileio
* operation to complete.
*/
if (semihosting->is_resumable && !semihosting->hit_fileio) {
- /* Resume right after the EBREAK 4 bytes instruction. */
- *retval = riscv_set_register(target, GDB_REGNO_PC, pc + 4);
- if (*retval != ERROR_OK)
- return SEMIHOSTING_ERROR;
-
LOG_DEBUG(" -> HANDLED");
return SEMIHOSTING_HANDLED;
}
-----------------------------------------------------------------------
Summary of changes:
src/target/riscv/riscv_semihosting.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
hooks/post-receive
--
Main OpenOCD repository
|