kvm: de-register mem region for MMIO (Glauber Costa)
Besides unassigned memory, we also don't care about MMIO. So if we're giving an MMIO area that is already registered, wipe it out. Signed-off-by: Glauber Costa <glommer@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5753 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
d5b4eb4016
commit
a3d6841ff8
|
@ -322,7 +322,7 @@ void kvm_set_phys_mem(target_phys_addr_t start_addr,
|
||||||
|
|
||||||
mem = kvm_lookup_slot(s, start_addr);
|
mem = kvm_lookup_slot(s, start_addr);
|
||||||
if (mem) {
|
if (mem) {
|
||||||
if (flags == IO_MEM_UNASSIGNED) {
|
if ((flags == IO_MEM_UNASSIGNED) || (flags >= TLB_MMIO)) {
|
||||||
mem->memory_size = 0;
|
mem->memory_size = 0;
|
||||||
mem->guest_phys_addr = start_addr;
|
mem->guest_phys_addr = start_addr;
|
||||||
mem->userspace_addr = 0;
|
mem->userspace_addr = 0;
|
||||||
|
|
Loading…
Reference in a new issue