From 2daf35021672e3e94341a8f6c929df68cb10dbf1 Mon Sep 17 00:00:00 2001 From: Tim Deegan Date: Thu, 15 Mar 2012 11:40:51 +0000 Subject: [PATCH] mm: guest_remove_page() should not populate or unshare. guest_remove_page() ought to use get_gfn_query() to look up the current state of the gfn. Otherwise it might populate or unshare the gfn just before dropping it. Signed-off-by: Tim Deegan Committed-by: Tim Deegan --- xen/common/memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/common/memory.c b/xen/common/memory.c index 907c6fdbde..3f02380fdf 100644 --- a/xen/common/memory.c +++ b/xen/common/memory.c @@ -162,7 +162,7 @@ int guest_remove_page(struct domain *d, unsigned long gmfn) unsigned long mfn; #ifdef CONFIG_X86 - mfn = mfn_x(get_gfn(d, gmfn, &p2mt)); + mfn = mfn_x(get_gfn_query(d, gmfn, &p2mt)); if ( unlikely(p2m_is_paging(p2mt)) ) { guest_physmap_remove_page(d, gmfn, mfn, 0); -- 2.30.2