You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
riscv-011: Don't trigger semihosting before the target is examined
In riscv-011 target, the handle_halt() function, and thus also
riscv_semihosting(), can get called from within examine() before
the examination is actually complete!
The chain of the function calls is:
- examine() -> riscv011_poll() -> poll_target()
-> handle_halt() -> riscv_semihosting()
If the target is already halted due to a breakpoint (dcsr.cause = SWBP)
at the time OpenOCD connects to it, semihosting will be attempted before
completing the examination, and the examination will fail.
This issue was observed on HiFive1 Rev A01.
Hot-fix this by making shure that semihosting is not attempted
before the target gets successfully examined.
Change-Id: Iccfa0da35d47a430d8674131ebd2eb8e5e2922c0
Signed-off-by: Jan Matyas <[email protected]>
0 commit comments