8 messages in com.xensource.lists.xen-ia64-develRe: [Xen-devel] [PATCH] fix memory ex...
FromSent OnAttachments
Isaku Yamahata15 Mar 2007 02:52.patch
Keir Fraser15 Mar 2007 03:59 
Isaku Yamahata15 Mar 2007 04:41 
Keir Fraser15 Mar 2007 05:22 
Isaku Yamahata15 Mar 2007 06:37 
Keir Fraser15 Mar 2007 06:58 
Isaku Yamahata15 Mar 2007 20:24 
Keir Fraser16 Mar 2007 01:07 
Subject:Re: [Xen-devel] [PATCH] fix memory exchange hypercall.
From:Isaku Yamahata (yama@valinux.co.jp)
Date:03/15/2007 08:24:54 PM
List:com.xensource.lists.xen-ia64-devel

On Thu, Mar 15, 2007 at 01:58:56PM +0000, Keir Fraser wrote:

- If the p2m entry is cleared which isn't followed by clearing PGC_allocaed and put_page() without any recording, there is no easy way to free the page until domain destruction.

This is true. Arguably guest_physmap_add_page() should test-and-clear PGC_allocated if there was already a page mapped at that address. Or it should fail. Or we should expect the guest not to do something this silly.

Really the correct answer is not immediately clear. I guess the first option makes most sense though, perhaps with a gdprintk(XENLOG_WARNING).

The ia64 p2m already adopted the first option without warning. So the guest_physmap_remove_page() depends on PGC_allocated bit. What's the expected behavior of guset_physmap_remove_page() with PGC_allocated? It shouldn't touch the bit?

Thanks a lot for your clarification. -- yamahata