[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen stable-4.9] memory: don't implicitly unpin for decrease-reservation



commit aafb8ac8b5071588d651096fb2a882680c24251a
Author:     Jan Beulich <jbeulich@xxxxxxxx>
AuthorDate: Tue Feb 27 14:22:48 2018 +0100
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Tue Feb 27 14:22:48 2018 +0100

    memory: don't implicitly unpin for decrease-reservation
    
    It very likely was a mistake (copy-and-paste from domain cleanup code)
    to implicitly unpin here: The caller should really unpin itself before
    (or after, if they so wish) requesting the page to be removed.
    
    This is XSA-252.
    
    Reported-by: Jann Horn <jannh@xxxxxxxxxx>
    Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
    Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
    master commit: d798a0952903db9d8ee0a580e03f214d2b49b7d7
    master date: 2018-02-27 14:03:27 +0100
---
 xen/common/memory.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/xen/common/memory.c b/xen/common/memory.c
index 2e5b44693c..c1d0da318e 100644
--- a/xen/common/memory.c
+++ b/xen/common/memory.c
@@ -341,9 +341,6 @@ int guest_remove_page(struct domain *d, unsigned long gmfn)
 
     rc = guest_physmap_remove_page(d, _gfn(gmfn), mfn, 0);
 
-    if ( !rc && test_and_clear_bit(_PGT_pinned, &page->u.inuse.type_info) )
-        put_page_and_type(page);
-
     /*
      * With the lack of an IOMMU on some platforms, domains with DMA-capable
      * device must retrieve the same pfn when the hypercall populate_physmap
--
generated by git-patchbot for /home/xen/git/xen.git#stable-4.9

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.