On Tue, Apr 17, 2018 at 01:16:41PM +0200, Andrea Bolognani wrote:
On Mon, 2018-04-09 at 17:20 +0200, Ján Tomko wrote:
> diff --git a/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
b/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
> index 6f332941ce..6a25e53175 100644
> --- a/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
> +++ b/tests/qemuxml2argvdata/aarch64-aavmf-virtio-mmio.args
> @@ -7,7 +7,7 @@ QEMU_AUDIO_DRV=none \
> /usr/bin/qemu-system-aarch64 \
> -name aarch64test \
> -S \
> --M virt \
> +-machine virt,accel=tcg \
> -cpu cortex-a53 \
> -m 1024 \
> -smp 1,sockets=1,cores=1,threads=1 \
>
> [ ... etc ...]
One of the hunks you snipped looks pretty interesting:
> diff --git a/tests/qemuxml2argvdata/controller-order.args
b/tests/qemuxml2argvdata/controller-order.args
> index 276f42fdce..7de96d5620 100644
> --- a/tests/qemuxml2argvdata/controller-order.args
> +++ b/tests/qemuxml2argvdata/controller-order.args
> @@ -7,8 +7,7 @@ QEMU_AUDIO_DRV=spice \
> /usr/bin/qemu-system-x86_64 \
> -name fdr \
> -S \
> --M rhel6.1.0 \
> --enable-kvm \
> +-machine rhel6.1.0,accel=kvm \
> -m 4096 \
> -smp 4,sockets=4,cores=1,threads=1 \
> -uuid d091ea82-29e6-2e34-3005-f02617b36e87 \
Unless I'm mistaken, we only use qemuBuildObsoleteAccelArg() (the
function that adds -enable-kvm) if we don't have -machine, which is
never going to be the case now, or we are asked for an accelerator
which is neither KVM or TCG, in which case we'll just error out.
As a follow-up cleanup patch, we should get rid of that function
altogether and turn the
if (def->virtType == VIR_DOMAIN_VIRT_QEMU)
virBufferAddLit(&buf, ",accel=tcg");
else if (def->virtType == VIR_DOMAIN_VIRT_KVM)
virBufferAddLit(&buf, ",accel=kvm");
else
obsoleteAccel = true;
from qemuBuildMachineCommandLine() into
switch ((virDomainVirtType) def->virtType) {
case VIR_DOMAIN_VIRT_QEMU:
virBufferAddLit(&buf, ",accel=tcg");
break;
case VIR_DOMAIN_VIRT_KVM:
virBufferAddLit(&buf, ",accel=kvm");
break;
default:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("the QEMU binary does not support %s"),
virDomainVirtTypeToString(def->virtType));
goto cleanup;
}
Right, it seems the other option for AccelArg was VIR_DOMAIN_VIRT_XEN:
commit 1f17ce215f8db809a2e5b77ef27412b7352e1451
qemu: Remove remnants of xenner support
(One of the many commits removing xenner support)
Jano