Comment 2 for bug 1940453

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

A change like the following could possibly fix the problem.

--- a/lib/qemu.c
+++ b/lib/qemu.c
@@ -309,7 +309,12 @@
 #ifdef MACHINE_TYPE
                            MACHINE_TYPE ","
 #endif
- "accel=kvm:tcg");
+#ifdef __riscv
+ "virt"
+#else
+ "accel=kvm:tcg"
+#endif
+ );
   guestfs_int_cmd_add_arg (cmd, "-device");

A better solution would be do detect the presence of KVM at runtime.