From mboxrd@z Thu Jan 1 00:00:00 1970 From: Keir Fraser Subject: Re: [PATCH 5/6] hvmloader: Change memory relocation loop when overlap with PCI hole. Date: Fri, 04 Nov 2011 14:52:03 +0000 Message-ID: References: <1320403109-8739-6-git-send-email-jean.guyader@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1320403109-8739-6-git-send-email-jean.guyader@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Jean Guyader , xen-devel@lists.xensource.com Cc: tim@xen.org, allen.m.kay@intel.com List-Id: xen-devel@lists.xenproject.org On 04/11/2011 10:38, "Jean Guyader" wrote: > > Change the way we relocate the memory page if they overlap with pci hole. > Use new map space (XENMAPSPACE_gmfn_range) to move the loop into xen. > > This code usually get triggered when a device is pass through to a guest > and the PCI hole has to be extended to have enough room to map the device > BARs. > The PCI hole will starts lower and it might overlap with some RAM that has > been > alocated for the guest. That usually happen if the guest has more than 4G of > RAM. > We have to relocate those pages in high mem otherwise they won't be > accessible. If the size field in the add_to_physmap structure is reduced to 16 bits, the new if() stmt will probably have to become a while() again. The new printf's are just excess verbiage. We dump the memory map as we exit hvmloader anyway. -- Keir > Signed-off-by: Jean Guyader > --- > tools/firmware/hvmloader/pci.c | 20 ++++++++++++++------ > 1 files changed, 14 insertions(+), 6 deletions(-) > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel