+accel=kvm:tcg
+cpu=
+machine=
+
+# Both libguestfs and virt-manager choose cpu=host when we think that
+# KVM is available, and default otherwise. Although testing for KVM
+# is hairy, I found that on aarch64 it can fail unless we choose
+# cpu=host for KVM.
+if test -r /dev/kvm; then
+ cpu=host
+fi
+
+# Default machine and CPU type depends on arch. You can override this
+# using -m|--machine and --cpu options.
+case "$canonical_arch" in
+ arm*)
+ machine=virt ;;
+ aarch*)
+ if [ "$cpu" = "" ]; then cpu=cortex-a57; fi
+ machine=virt ;;
+esac