From mboxrd@z Thu Jan 1 00:00:00 1970 From: Glauber Costa Subject: Re: [PATCH 4/9] substitute is_allocated_mem with more general is_containing_region Date: Tue, 23 Sep 2008 13:19:44 -0300 Message-ID: <20080923161944.GC3583@poweredge.glommer> References: <1221840506-22996-1-git-send-email-glommer@redhat.com> <1221840506-22996-5-git-send-email-glommer@redhat.com> <48D54214.5080501@redhat.com> <20080922135117.GC3618@poweredge.glommer> <48D89C3C.3080502@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: kvm@vger.kernel.org, aliguori@us.ibm.com To: Avi Kivity Return-path: Received: from mx2.redhat.com ([66.187.237.31]:53354 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751205AbYIWQTN (ORCPT ); Tue, 23 Sep 2008 12:19:13 -0400 Content-Disposition: inline In-Reply-To: <48D89C3C.3080502@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Tue, Sep 23, 2008 at 10:35:24AM +0300, Avi Kivity wrote: > Glauber Costa wrote: >> On Sat, Sep 20, 2008 at 11:33:56AM -0700, Avi Kivity wrote: >> >>> Glauber Costa wrote: >>> >>>> is_allocated_mem is a function that checks if every relevant aspect of the memory slot >>>> match (start and size). Replace it with a more generic function that checks if a memory >>>> region is totally contained into another. The former case is also covered. >>>> >>> I think enabling dirty page tracking requires the slot to match exactly. >>> >> >> The registering function was the only caller for that. As dirty tracking was happening >> _inside_ it, so we're not really losing anything here. >> >> That said, I believe in the future, it will. (would be a logical next step, and start >> addressing the problem that Jan raised). Maybe we can keep the function that checks for >> exact matching, but another alternative is to pass a phys_addr, and turn dirty tracking on/off >> for whatever slot that contains that phys_addr. What do you think? >> > > Exact matching would avoid surprises (catch errors early). Agreed, you're right. However, as I said, this is for future reference, because right now, we don't change slots properties via the memory registration infrastructure once it's in place. > > -- > error compiling committee.c: too many arguments to function >