]> git.proxmox.com Git - mirror_qemu.git/commitdiff
memory: Move owner-less MemoryRegions to /machine/unattached
authorAndreas Färber <afaerber@suse.de>
Thu, 12 Mar 2015 14:37:07 +0000 (15:37 +0100)
committerAndreas Färber <afaerber@suse.de>
Tue, 17 Mar 2015 13:31:26 +0000 (14:31 +0100)
This cleans up the official /machine namespace. In particular
/machine/system[0] and /machine/io[0], as well as entries with
non-sanitized node names such as "/machine/qemu extended regs[0]".

The actual MemoryRegion names remain unchanged.

Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Tested-by: Alistair Francis <alistair.francis@xilinx.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
memory.c

index 20f6d9eeac737609c3d47da7f01cde7d237c390c..ee3f2a8a954ef3cc3c15871e8e9d17608c46c0ab 100644 (file)
--- a/memory.c
+++ b/memory.c
@@ -868,7 +868,7 @@ void memory_region_init(MemoryRegion *mr,
                         uint64_t size)
 {
     if (!owner) {
-        owner = qdev_get_machine();
+        owner = container_get(qdev_get_machine(), "/unattached");
     }
 
     object_initialize(mr, sizeof(*mr), TYPE_MEMORY_REGION);