diff options
author | Xiao Guangrong <guangrong.xiao@linux.intel.com> | 2016-11-07 19:13:38 +0800 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2016-11-15 17:20:37 +0200 |
commit | 75f27498220e6ff6f78bf08fbe2cc662ec76ba89 (patch) | |
tree | f68f4b39df6fa145fe4d6e010f089f9c9967cd47 /hw/acpi/piix4.c | |
parent | 12f86b5b3e1bdf75e0a467d771c16cc42f3a1f1a (diff) | |
download | qemu-75f27498220e6ff6f78bf08fbe2cc662ec76ba89.tar.gz qemu-75f27498220e6ff6f78bf08fbe2cc662ec76ba89.tar.bz2 qemu-75f27498220e6ff6f78bf08fbe2cc662ec76ba89.zip |
pc: memhp: move nvdimm hotplug out of memory hotplug
as they use completely different way to handle hotplug event
Suggested-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Xiao Guangrong <guangrong.xiao@linux.intel.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Diffstat (limited to 'hw/acpi/piix4.c')
-rw-r--r-- | hw/acpi/piix4.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c index 2adc246b00..17d36bd595 100644 --- a/hw/acpi/piix4.c +++ b/hw/acpi/piix4.c @@ -378,7 +378,12 @@ static void piix4_device_plug_cb(HotplugHandler *hotplug_dev, if (s->acpi_memory_hotplug.is_enabled && object_dynamic_cast(OBJECT(dev), TYPE_PC_DIMM)) { - acpi_memory_plug_cb(hotplug_dev, &s->acpi_memory_hotplug, dev, errp); + if (object_dynamic_cast(OBJECT(dev), TYPE_NVDIMM)) { + nvdimm_acpi_plug_cb(hotplug_dev, dev); + } else { + acpi_memory_plug_cb(hotplug_dev, &s->acpi_memory_hotplug, + dev, errp); + } } else if (object_dynamic_cast(OBJECT(dev), TYPE_PCI_DEVICE)) { acpi_pcihp_device_plug_cb(hotplug_dev, &s->acpi_pci_hotplug, dev, errp); } else if (object_dynamic_cast(OBJECT(dev), TYPE_CPU)) { |