From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L2oh6-0001DL-M4 for qemu-devel@nongnu.org; Wed, 19 Nov 2008 10:10:16 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L2oh4-0001Cg-W4 for qemu-devel@nongnu.org; Wed, 19 Nov 2008 10:10:16 -0500 Received: from [199.232.76.173] (port=34482 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L2oh4-0001Cd-SH for qemu-devel@nongnu.org; Wed, 19 Nov 2008 10:10:14 -0500 Received: from wf-out-1314.google.com ([209.85.200.168]:55865) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1L2oh2-0003zi-Uu for qemu-devel@nongnu.org; Wed, 19 Nov 2008 10:10:13 -0500 Received: by wf-out-1314.google.com with SMTP id 27so3737362wfd.4 for ; Wed, 19 Nov 2008 07:10:11 -0800 (PST) Message-ID: <49242C4F.8000206@codemonkey.ws> Date: Wed, 19 Nov 2008 09:10:07 -0600 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 4/6] kvm: de-register mem region for MMIO. References: <1227108377-8442-1-git-send-email-glommer@redhat.com> <1227108377-8442-2-git-send-email-glommer@redhat.com> <1227108377-8442-3-git-send-email-glommer@redhat.com> <1227108377-8442-4-git-send-email-glommer@redhat.com> <1227108377-8442-5-git-send-email-glommer@redhat.com> In-Reply-To: <1227108377-8442-5-git-send-email-glommer@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Glauber Costa wrote: > 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. > Applied. Thanks. Regards, Anthony Liguori > Signed-off-by: Glauber Costa > --- > kvm-all.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/kvm-all.c b/kvm-all.c > index b5bbdcb..9700e50 100644 > --- a/kvm-all.c > +++ b/kvm-all.c > @@ -344,7 +344,7 @@ void kvm_set_phys_mem(target_phys_addr_t start_addr, > > mem = kvm_lookup_slot(s, start_addr); > if (mem) { > - if (flags == IO_MEM_UNASSIGNED) { > + if ((flags == IO_MEM_UNASSIGNED) || (flags >= TLB_MMIO)) { > mem->memory_size = 0; > mem->guest_phys_addr = start_addr; > mem->userspace_addr = 0; >