pc: fail memory hot-plug/unplug with -no-acpi and Q35 machine type
commit8cd91acec8dfea6065272ca828405333f564a612
authorHaozhong Zhang <haozhong.zhang@intel.com>
Fri, 22 Dec 2017 01:51:20 +0000 (22 09:51 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 12 Jan 2018 08:54:13 +0000 (12 09:54 +0100)
treeae567bfb1cf88c21b6e02cd2272fcd727922f953
parent2770c90d432b571cab718e28f838097f0b2201ec
pc: fail memory hot-plug/unplug with -no-acpi and Q35 machine type

When -no-acpi option is used with Q35 machine type, no guest ACPI is
built, but the ACPI device is still created, so only checking the
presence of ACPI device before memory plug/unplug is not enough in
such cases. Check whether ACPI is disabled globally in addition and
fail memory plug/unplug if it's disabled.

Signed-off-by: Haozhong Zhang <haozhong.zhang@intel.com>
Message-Id: <20171222015120.31730-1-haozhong.zhang@intel.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
hw/i386/pc.c