Set CPU type for mipsel, mips64el
authorHilko Bengen <bengen@debian.org>
Thu, 30 Dec 2021 20:05:43 +0000 (21:05 +0100)
committerHilko Bengen <bengen@debian.org>
Sat, 26 Oct 2024 10:47:48 +0000 (12:47 +0200)
Gbp-Pq: Name Set-CPU-type-for-mipsel-mips64el.patch

lib/appliance-cpu.c

index 57745973c05ef2a56e1fdc2208149972fda9c333..27969cd7d93626f01f3734f6d8479a7447efe370 100644 (file)
@@ -87,6 +87,12 @@ guestfs_int_get_cpu_model (int kvm)
 #elif defined(__riscv)
   /* qemu-system-riscv64 (7.0) doesn't yet support -cpu max */
   return NULL;
+#elif defined(__mips64)
+  /* Taken from https://gist.github.com/bradfa/46ceff759a0cf9f392cc069c4f0f095a */
+  return "5KEc";
+#elif defined(__mips)
+  /* Guessed from mips64 */
+  return "4KEc";
 #else
   /* On most architectures we can use "max" to get the best possible CPU.
    * For recent qemu this should work even on TCG.