From: Peter Krempa Date: Mon, 6 Mar 2023 14:30:33 +0000 (+0100) Subject: qemu: command: Replace check using QEMU_CAPS_NO_ACPI with architecture check X-Git-Tag: v9.2.0-rc1~150 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dfc4a9c79601b6b9c73386840331613f40d42aba;p=thirdparty%2Flibvirt.git qemu: command: Replace check using QEMU_CAPS_NO_ACPI with architecture check QEMU_CAPS_NO_ACPI is asserted based on architecture, so it can be replaced by a non-capability check. Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 7a1cff1fd0..189be55537 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -5969,7 +5969,9 @@ qemuBuildPMCommandLine(virCommand *cmd, /* Use old syntax of -no-acpi only if qemu didn't report that it supports the * new syntax */ if (virQEMUCapsMachineSupportsACPI(qemuCaps, def->virtType, def->os.machine) == VIR_TRISTATE_BOOL_ABSENT && - virQEMUCapsGet(qemuCaps, QEMU_CAPS_NO_ACPI)) { + (def->os.arch == VIR_ARCH_I686 || + def->os.arch == VIR_ARCH_X86_64 || + def->os.arch == VIR_ARCH_AARCH64)) { if (def->features[VIR_DOMAIN_FEATURE_ACPI] != VIR_TRISTATE_SWITCH_ON) virCommandAddArg(cmd, "-no-acpi"); }