]> git.proxmox.com Git - mirror_qemu.git/commit - memory.c
memory: update coalesced_range on transaction_commit
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 28 Nov 2018 16:28:45 +0000 (17:28 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 11 Jan 2019 12:57:24 +0000 (13:57 +0100)
commit3ac7d43a6fbb5d4a3d01fc9a055c218030af3727
tree8b7797d4607c57ff4b831a24b080d7504e7840ac
parent1f7af8042903a5eeb2f707efff34175162f75664
memory: update coalesced_range on transaction_commit

The e1000 driver calls memory_region_add_coalescing but
kvm_coalesce_mmio_region is never called for those regions.  The bug
dates back to the introduction of the memory region API; to fix it,
delete and re-add coalesced MMIO ranges when building the FlatViews.

Because coalesced MMIO regions apply to all address spaces, the
has_coalesced_range flag has to be changed into an int.

Fixes: 093bc2cd885e ("Hierarchical memory region API")
Reported-by: Atsushi Nemoto <atsushi.nemoto@sord.co.jp>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
memory.c