From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Vrabel Subject: Re: [PATCH 0/4] xen: map foreign pages for shared rings by updating the PTEs directly Date: Thu, 29 Sep 2011 17:45:52 +0100 Message-ID: <4E84A0C0.6000804@citrix.com> References: <1317311612-15220-1-git-send-email-david.vrabel@citrix.com> <4E84B3FE02000078000588A9@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4E84B3FE02000078000588A9@nat28.tlf.novell.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: Jan Beulich Cc: "xen-devel@lists.xensource.com" , Rzeszutek Wilk , Konrad List-Id: xen-devel@lists.xenproject.org On 29/09/11 17:07, Jan Beulich wrote: >>>> On 29.09.11 at 17:53, David Vrabel wrote: >> [Resend as requested by Konrad.] >> >> This series of patches allows the vmalloc_sync_all() to be removed >> from alloc_vm_area() by getting the hypervisor to update the PTEs (in >> init_mm) directly rather than having the hypervisor look in the >> current page tables to find the PTEs. >> >> Once the hypervisor has updated the PTEs, the normal mechanism of >> syncing the page tables after a fault works as expected. > > Did you actually test that, and namely the case where alloc_vm_area() > would result in a new top level page directory entry to get populated? > > I cannot see how this new entry would propagate into other mm-s, and > hence I cannot see how you can do away with calling vmalloc_sync_all() > just by changing how leaf page table entries get populated. I don't think this new behaviour of alloc_vm_area() is any different from how a regular vmalloc() works. vmalloc_fault() copies the page table entries from init_mm into the current MM (on 32-bit it calls vmalloc_sync_one() which makes it obviously correct I think). David >> This mechanism doesn't currently work on the ia64 port as that does >> not support the GNTMAP_contains_pte flag. >> >> David