On 11/29/18 5:36 PM, Cédric Le Goater wrote: > On 11/29/18 5:09 AM, David Gibson wrote: >> On Fri, Nov 16, 2018 at 11:57:20AM +0100, Cédric Le Goater wrote: >>> This will be used to remove the MMIO regions of the POWER9 XIVE >>> interrupt controller when the sPAPR machine is reseted. >>> >>> Signed-off-by: Cédric Le Goater <[email protected]> >> >> Reviewed-by: David Gibson <[email protected]> >> >> Since the code looks sane. >> >> Hoever, I think using memory_region_set_enabled() would be a better >> idea for our purposes than actually adding/deleting the subregion. > > Yes and we might not need this one anymore.
As we are destroying the KVM device, we also need to remove the mmap in QEMU, else we will have a VMA with a page fault handler pointing on a bogus KVM device. which means destroying the memory region, so we can not use memory_region_set_enabled(). Anyhow mapping/unmapping works well. Thanks, C.
