WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] grant table and bogus mfns

To: Kieran Mansley <kmansley@xxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] grant table and bogus mfns
From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Date: Tue, 13 Nov 2007 16:45:49 +0000
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 13 Nov 2007 08:46:45 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <1194972004.4124.31.camel@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcgmFKUH49kbCpIHEdytjwAX8io7RQ==
Thread-topic: [Xen-devel] [PATCH] grant table and bogus mfns
User-agent: Microsoft-Entourage/11.3.6.070618
On 13/11/07 16:40, "Kieran Mansley" <kmansley@xxxxxxxxxxxxxx> wrote:

> I'm slightly surprised that without the call to iomem_permit_access() I
> don't trip over the iomem_access_permitted() check in
> xen/arch/x86/mm.c:get_page_from_l1e() when the grant is mapped.  I hope
> this doesn't indicate that I've missed something.

get_page_from_l1e() is not executed on the map_grant path, which explains
this behaviour.

As for GNTMAP_nocache, I think actually we should not trust the mapper to
get the cache attributes correct (because sometimes if the attributes are
wrong the system can be destabilised). Actually we now in xen-unstable have
cache-attribute tracking for RAM pages. The cache attributes for the granted
mapping should pick up PAT/PWT/PCD from the page's count_info field. If dom0
has the page mapped with the right attributes this will then do the right
thing immediately. If dom0 doesn't have the page mapped then we'll need to
do a bit more work...

 -- Keir



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel