acpi, mem-hotplug: use PC_DIMM_SLOT_PROP in acpi_memory_plug_cb().
authorTang Chen <tangchen@cn.fujitsu.com>
Thu, 26 Feb 2015 01:16:43 +0000 (09:16 +0800)
committerMichael S. Tsirkin <mst@redhat.com>
Sun, 1 Mar 2015 17:33:14 +0000 (18:33 +0100)
Replace string "slot" in acpi_memory_plug_cb() with macro PC_DIMM_SLOT_PROP.

Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Tang Chen <tangchen@cn.fujitsu.com>
Signed-off-by: Zhu Guihua <zhugh.fnst@cn.fujitsu.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/acpi/memory_hotplug.c

index ed39241..c6580da 100644 (file)
@@ -168,7 +168,8 @@ void acpi_memory_plug_cb(ACPIREGS *ar, qemu_irq irq, MemHotplugState *mem_st,
 {
     MemStatus *mdev;
     Error *local_err = NULL;
-    int slot = object_property_get_int(OBJECT(dev), "slot", &local_err);
+    int slot = object_property_get_int(OBJECT(dev), PC_DIMM_SLOT_PROP,
+                                       &local_err);
 
     if (local_err) {
         error_propagate(errp, local_err);