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] On suspend, canonicalize store and console mfns in the g

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] On suspend, canonicalize store and console mfns in the guest.
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 05 Sep 2005 15:34:10 +0000
Delivery-date: Mon, 05 Sep 2005 15:32:36 +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 cl349@xxxxxxxxxxxxxxxxxxxx
# Node ID ff14bb5600c9c7b23b4aff1b277fc731f6c4a622
# Parent  1f460d0fd6c672a573b825a28200715011ba982d
On suspend, canonicalize store and console mfns in the guest.
Signed-off-by: Christian Limpach <Christian.Limpach@xxxxxxxxxxxx>

diff -r 1f460d0fd6c6 -r ff14bb5600c9 
linux-2.6-xen-sparse/arch/xen/kernel/reboot.c
--- a/linux-2.6-xen-sparse/arch/xen/kernel/reboot.c     Mon Sep  5 14:54:05 2005
+++ b/linux-2.6-xen-sparse/arch/xen/kernel/reboot.c     Mon Sep  5 15:32:14 2005
@@ -177,6 +177,9 @@
     HYPERVISOR_shared_info = (shared_info_t *)empty_zero_page;
     clear_fixmap(FIX_SHARED_INFO);
 
+    xen_start_info.store_mfn = mfn_to_pfn(xen_start_info.store_mfn);
+    xen_start_info.console_mfn = mfn_to_pfn(xen_start_info.console_mfn);
+
     /* We'll stop somewhere inside this hypercall.  When it returns,
        we'll start resuming after the restore. */
     HYPERVISOR_suspend(virt_to_mfn(xen_start_info));
diff -r 1f460d0fd6c6 -r ff14bb5600c9 tools/libxc/xc_linux_save.c
--- a/tools/libxc/xc_linux_save.c       Mon Sep  5 14:54:05 2005
+++ b/tools/libxc/xc_linux_save.c       Mon Sep  5 15:32:14 2005
@@ -434,9 +434,6 @@
     /* base of the region in which domain memory is mapped */
     unsigned char *region_base = NULL;
 
-    /* A temporary mapping of the guest's start_info page. */
-    start_info_t *start_info = NULL;
-
     /* number of pages we're dealing with */
     unsigned long nr_pfns;
 
@@ -667,28 +664,6 @@
     if (write(io_fd, pfn_to_mfn_frame_list, PAGE_SIZE) != PAGE_SIZE) {
         ERR("write: pfn_to_mfn_frame_list");
         goto out;
-    }
-
-    /* Map the suspend-record MFN to pin it. The page must be owned by 
-       dom for this to succeed. */
-    start_info = xc_map_foreign_range(xc_handle, dom, PAGE_SIZE,
-                                     PROT_READ | PROT_WRITE, 
-                                     ctxt.user_regs.esi);
-    if (!start_info){
-        ERR("Couldn't map start_info page");
-        goto out;
-    }
-
-    /* Canonicalize store mfn. */
-    if ( !translate_mfn_to_pfn(&start_info->store_mfn) ) {
-       ERR("Store frame is not in range of pseudophys map");
-       goto out;
-    }
-
-    /* Canonicalize console mfn. */
-    if ( !translate_mfn_to_pfn(&start_info->console_mfn) ) {
-       ERR("Console frame is not in range of pseudophys map");
-       goto out;
     }
 
     print_stats( xc_handle, dom, 0, &stats, 0 );
@@ -1062,9 +1037,6 @@
     if(live_shinfo)
         munmap(live_shinfo, PAGE_SIZE);
 
-    if(start_info) 
-        munmap(start_info, PAGE_SIZE);
-
     if(live_pfn_to_mfn_frame_list) 
         munmap(live_pfn_to_mfn_frame_list, PAGE_SIZE);
 

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] On suspend, canonicalize store and console mfns in the guest., Xen patchbot -unstable <=