]> git.proxmox.com Git - mirror_qemu.git/commit - memory.c
memory: add ref/unref calls
authorPaolo Bonzini <pbonzini@redhat.com>
Mon, 6 May 2013 08:46:11 +0000 (10:46 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 4 Jul 2013 15:42:45 +0000 (17:42 +0200)
commitdfde4e6e1a868f60033ece0590b1f75e6c57fa16
treea84c1cddd96c6dc60fd7a5d35949b4fcaf9a32ed
parent3ce10901ca8da9142dcdcde198fda1a4c290934c
memory: add ref/unref calls

Add ref/unref calls at the following places:

- places where memory regions are stashed by a listener and
  used outside the BQL (including in Xen or KVM).

- memory_region_find callsites

- creation of aliases and containers (only the aliased/contained
  region gets a reference to avoid loops)

- around calls to del_subregion/add_subregion, where the region
  could disappear after the first call

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
16 files changed:
exec.c
hw/core/loader.c
hw/display/exynos4210_fimd.c
hw/display/framebuffer.c
hw/i386/kvmvapic.c
hw/misc/vfio.c
hw/virtio/dataplane/hostmem.c
hw/virtio/vhost.c
hw/virtio/virtio-balloon.c
hw/xen/xen_pt.c
include/hw/virtio/dataplane/hostmem.h
kvm-all.c
memory.c
target-arm/kvm.c
target-sparc/mmu_helper.c
xen-all.c