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] bogus gfn - mfn - gfn - mfn checks in guest_physmap_add_

To: Olaf Hering <olaf@xxxxxxxxx>
Subject: Re: [Xen-devel] bogus gfn - mfn - gfn - mfn checks in guest_physmap_add_entry
From: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Date: Thu, 25 Nov 2010 15:32:16 +0000
Cc: Patrick Colp <pjcolp@xxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 25 Nov 2010 07:33:45 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20101125150310.GA12431@xxxxxxxxx>
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20101123210158.GA9425@xxxxxxxxx> <20101124102202.GF19638@xxxxxxxxxxxxxxxxxxxxxxx> <20101124144138.GA25619@xxxxxxxxx> <20101124145326.GH19638@xxxxxxxxxxxxxxxxxxxxxxx> <20101125150310.GA12431@xxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.20 (2009-06-14)
At 15:03 +0000 on 25 Nov (1290697390), Olaf Hering wrote:
> On Wed, Nov 24, Tim Deegan wrote:
> 
> > The problem is that PV guests set their own m2p entries and can't be
> > relied on to tear them down.  
> 
> What needs to happen for PV guests?
> Dont they use the machine_to_phys_mapping[] array like HVM guests?

They do, but they can put whatever they like in it, and don't have to
clean up afterwards.

> I see memory_exchange uses assign_pages() to move mfns from one domain
> to another (havent studied the whole function yet). I think thats
> another place that needs an audit wether the machine_to_phys_mapping[]
> array is maintained properly.

Good catch.  It might be better to hook page_set_owner(), which ought to
imply that the old m2p info is stale.   I had a quick look at all its
callers and I _think_ it would be OK, but I haven't tested that at 
all. :)

Tim.

-- 
Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Principal Software Engineer, Xen Platform Team
Citrix Systems UK Ltd.  (Company #02937203, SL9 0BG)

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