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] [xen-unstable] libxl, xl: Account for shadow memory for

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] libxl, xl: Account for shadow memory for PV guests too
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 24 Nov 2010 10:25:14 -0800
Delivery-date: Wed, 24 Nov 2010 10:26:00 -0800
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/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/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 Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
# Date 1290540300 0
# Node ID b609b1b983d646f19a6bdb5066368cfdc64796e8
# Parent  9ffd785319e09bc9a655d320f77d655ebec42514
libxl, xl: Account for shadow memory for PV guests too

We need to account for the memory needed by shadow pagetables even for PV
guests, because in that case shadow pagetables are used during live
migration.

Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
 tools/libxl/libxl.c      |    2 +-
 tools/libxl/xl_cmdimpl.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff -r 9ffd785319e0 -r b609b1b983d6 tools/libxl/libxl.c
--- a/tools/libxl/libxl.c       Tue Nov 23 19:23:22 2010 +0000
+++ b/tools/libxl/libxl.c       Tue Nov 23 19:25:00 2010 +0000
@@ -3026,7 +3026,7 @@ int libxl_domain_need_memory(libxl_ctx *
         if (strstr(dm_info->device_model, "stubdom-dm"))
             *need_memkb += 32 * 1024;
     } else
-        *need_memkb += LIBXL_PV_EXTRA_MEMORY;
+        *need_memkb += b_info->shadow_memkb + LIBXL_PV_EXTRA_MEMORY;
     if (*need_memkb % (2 * 1024))
         *need_memkb += (2 * 1024) - (*need_memkb % (2 * 1024));
     return 0;
diff -r 9ffd785319e0 -r b609b1b983d6 tools/libxl/xl_cmdimpl.c
--- a/tools/libxl/xl_cmdimpl.c  Tue Nov 23 19:23:22 2010 +0000
+++ b/tools/libxl/xl_cmdimpl.c  Tue Nov 23 19:25:00 2010 +0000
@@ -332,8 +332,8 @@ static void init_build_info(libxl_domain
     b_info->target_memkb = b_info->max_memkb;
     b_info->disable_migrate = 0;
     b_info->cpuid = NULL;
+    b_info->shadow_memkb = 0;
     if (c_info->hvm) {
-        b_info->shadow_memkb = 0; /* Set later */
         b_info->video_memkb = 8 * 1024;
         b_info->kernel.path = strdup("hvmloader");
         b_info->hvm = 1;

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] libxl, xl: Account for shadow memory for PV guests too, Xen patchbot-unstable <=