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] xend: Support HVM S3 resume.

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] xend: Support HVM S3 resume.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 20 May 2008 12:50:17 -0700
Delivery-date: Tue, 20 May 2008 12:50:23 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1211291445 -3600
# Node ID 672c09aad49df0b8056c795bd6c351746d037975
# Parent  7c752689b0eaeff1cc68e39931040d0bda04aa25
xend: Support HVM S3 resume.
Signed-off-by: Yu Ke <ke.yu@xxxxxxxxx>
Signed-off-by: Ke Liping <liping.ke@xxxxxxxxx>
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 tools/python/xen/xend/XendConstants.py |    5 ++++-
 tools/python/xen/xend/XendDomain.py    |    3 +++
 tools/python/xen/xm/main.py            |    2 +-
 3 files changed, 8 insertions(+), 2 deletions(-)

diff -r 7c752689b0ea -r 672c09aad49d tools/python/xen/xend/XendConstants.py
--- a/tools/python/xen/xend/XendConstants.py    Tue May 20 14:36:05 2008 +0100
+++ b/tools/python/xen/xend/XendConstants.py    Tue May 20 14:50:45 2008 +0100
@@ -48,6 +48,7 @@ HVM_PARAM_BUFPIOREQ_PFN = 9
 HVM_PARAM_BUFPIOREQ_PFN = 9
 HVM_PARAM_TIMER_MODE   = 10
 HVM_PARAM_HPET_ENABLED = 11
+HVM_PARAM_ACPI_S_STATE = 14
 
 restart_modes = [
     "restart",
@@ -102,11 +103,13 @@ TRIGGER_NMI   = 0
 TRIGGER_NMI   = 0
 TRIGGER_RESET = 1
 TRIGGER_INIT  = 2
+TRIGGER_S3RESUME = 3
 
 TRIGGER_TYPE = {
     "nmi"   : TRIGGER_NMI,
     "reset" : TRIGGER_RESET,
-    "init"  : TRIGGER_INIT
+    "init"  : TRIGGER_INIT,
+    "s3resume": TRIGGER_S3RESUME
 }
 
 #
diff -r 7c752689b0ea -r 672c09aad49d tools/python/xen/xend/XendDomain.py
--- a/tools/python/xen/xend/XendDomain.py       Tue May 20 14:36:05 2008 +0100
+++ b/tools/python/xen/xend/XendDomain.py       Tue May 20 14:50:45 2008 +0100
@@ -1657,6 +1657,9 @@ class XendDomain:
             trigger = TRIGGER_TYPE[trigger_name.lower()]
         else:
             raise XendError("Invalid trigger: %s" % trigger_name)
+        if trigger == TRIGGER_S3RESUME:
+            xc.hvm_set_param(dominfo.getDomid(), HVM_PARAM_ACPI_S_STATE, 0)
+            return None
         try:
             return xc.domain_send_trigger(dominfo.getDomid(),
                                           trigger,
diff -r 7c752689b0ea -r 672c09aad49d tools/python/xen/xm/main.py
--- a/tools/python/xen/xm/main.py       Tue May 20 14:36:05 2008 +0100
+++ b/tools/python/xen/xm/main.py       Tue May 20 14:50:45 2008 +0100
@@ -143,7 +143,7 @@ SUBCOMMAND_HELP = {
                      'Get/set credit scheduler parameters.'),
     'sysrq'       : ('<Domain> <letter>', 'Send a sysrq to a domain.'),
     'debug-keys'  : ('<Keys>', 'Send debug keys to Xen.'),
-    'trigger'     : ('<Domain> <nmi|reset|init> [<VCPU>]',
+    'trigger'     : ('<Domain> <nmi|reset|init|s3resume> [<VCPU>]',
                      'Send a trigger to a domain.'),
     'vcpu-list'   : ('[Domain, ...]',
                      'List the VCPUs for all/some domains.'),

_______________________________________________
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] xend: Support HVM S3 resume., Xen patchbot-unstable <=