Created attachment 252003 [details] git patch Hi. To use the Spike RISC-V emulator with gdb (see e.g. the instructions in https://github.com/riscv-software-src/riscv-isa-sim), openocd must be compiled with the remote bitbang option turned on. As the openocd port currently does not have this option, I propose the patch, which is in attachment, to address this issue. Furthermore, I propose that this option is enabled by default, also reflected in the attached patch.
Created attachment 252004 [details] git patch
Have you actually been able to successfully use the port with remote bitbanging enabled? It has been a while but I seem to recall that something prevented the bitbanging driver from working under FreeBSD. But that might have just been the Linux GPIO bitbanging driver.
Hi. What I can report/confirm is that I was successful in using the remote bitbanging as in the example given in the website I posted (i.e. debugging RISC-V with the spike emulator).
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=63f1ac9a402f267ee416f5209e07d8133dd1226a commit 63f1ac9a402f267ee416f5209e07d8133dd1226a Author: Tiago Gasiba <tiago.gasiba@gmai.com> AuthorDate: 2024-07-12 21:53:41 +0000 Commit: Joel Bodenmann <jbo@FreeBSD.org> CommitDate: 2024-07-14 20:29:39 +0000 devel/openocd: Add option for remote-bitbang driver PR: 280250 Approved by: tcberner (mentor) Differential Revision: https://reviews.freebsd.org/D45975 devel/openocd/Makefile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
Committed - Thanks!