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-changelog

[Xen-changelog] There is no need to pin page tables when XENFEAT_writabl

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] There is no need to pin page tables when XENFEAT_writable_page_tables
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 15 Mar 2006 18:50:09 +0000
Delivery-date: Wed, 15 Mar 2006 18:51:33 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Ian.Campbell@xxxxxxxxxxxxx
# Node ID f00e257d200c0178e15eb32a0cb1fbf66e739971
# Parent  06e3c5ef29797bb73065b785fca1ae6a141217d8
There is no need to pin page tables when XENFEAT_writable_page_tables
is enabled.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxxxxx>

diff -r 06e3c5ef2979 -r f00e257d200c 
linux-2.6-xen-sparse/arch/i386/mm/pgtable-xen.c
--- a/linux-2.6-xen-sparse/arch/i386/mm/pgtable-xen.c   Wed Mar 15 10:09:20 2006
+++ b/linux-2.6-xen-sparse/arch/i386/mm/pgtable-xen.c   Wed Mar 15 10:33:43 2006
@@ -587,6 +587,8 @@
 
 void mm_pin(struct mm_struct *mm)
 {
+       if (xen_feature(XENFEAT_writable_page_tables))
+           return;
        spin_lock(&mm->page_table_lock);
        __pgd_pin(mm->pgd);
        spin_unlock(&mm->page_table_lock);
@@ -594,6 +596,8 @@
 
 void mm_unpin(struct mm_struct *mm)
 {
+       if (xen_feature(XENFEAT_writable_page_tables))
+           return;
        spin_lock(&mm->page_table_lock);
        __pgd_unpin(mm->pgd);
        spin_unlock(&mm->page_table_lock);
@@ -602,6 +606,8 @@
 void mm_pin_all(void)
 {
        struct page *page;
+       if (xen_feature(XENFEAT_writable_page_tables))
+           return;
        for (page = pgd_list; page; page = (struct page *)page->index) {
                if (!test_bit(PG_pinned, &page->flags))
                        __pgd_pin((pgd_t *)page_address(page));
diff -r 06e3c5ef2979 -r f00e257d200c 
linux-2.6-xen-sparse/arch/x86_64/mm/pageattr-xen.c
--- a/linux-2.6-xen-sparse/arch/x86_64/mm/pageattr-xen.c        Wed Mar 15 
10:09:20 2006
+++ b/linux-2.6-xen-sparse/arch/x86_64/mm/pageattr-xen.c        Wed Mar 15 
10:33:43 2006
@@ -71,6 +71,9 @@
 
 void mm_pin(struct mm_struct *mm)
 {
+       if (xen_feature(XENFEAT_writable_page_tables))
+               return;
+
        spin_lock(&mm->page_table_lock);
 
        mm_walk(mm, PAGE_KERNEL_RO);
@@ -94,6 +97,9 @@
 
 void mm_unpin(struct mm_struct *mm)
 {
+       if (xen_feature(XENFEAT_writable_page_tables))
+               return;
+
        spin_lock(&mm->page_table_lock);
 
        xen_pgd_unpin(__pa(mm->pgd));
@@ -116,6 +122,9 @@
 
 void mm_pin_all(void)
 {
+       if (xen_feature(XENFEAT_writable_page_tables))
+               return;
+
        while (!list_empty(&mm_unpinned))       
                mm_pin(list_entry(mm_unpinned.next, struct mm_struct,
                                  context.unpinned));

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] There is no need to pin page tables when XENFEAT_writable_page_tables, Xen patchbot -unstable <=