diff --git a/usr.sbin/bhyve/riscv/vmexit.c b/usr.sbin/bhyve/riscv/vmexit.c index e2efd53bded..233dba9f3c7 100644 --- a/usr.sbin/bhyve/riscv/vmexit.c +++ b/usr.sbin/bhyve/riscv/vmexit.c @@ -47,6 +47,7 @@ #include #include #include +#include #include @@ -135,6 +136,12 @@ vmexit_debug(struct vmctx *ctx __unused, struct vcpu *vcpu __unused, struct vm_run *vmrun __unused) { + /* + * XXX-MJ sleep for a short period to avoid chewing up the CPU in the + * window between activation of the vCPU thread and the + * SBI_HSM_HART_START request. + */ + usleep(1000); return (VMEXIT_CONTINUE); }