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/
Home Products Support Community News


[Xen-changelog] [xen-unstable] libxl: allow guest to write "control/shut

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] libxl: allow guest to write "control/shutdown" xenstore node.
From: Xen patchbot-unstable <patchbot@xxxxxxx>
Date: Tue, 15 Feb 2011 00:35:17 -0800
Delivery-date: Tue, 15 Feb 2011 00:35:49 -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 Ian Campbell <ian.campbell@xxxxxxxxxx>
# Date 1297446984 0
# Node ID c4b843d0b5f4c873f61ba88849217019d7f7f885
# Parent  9280f16747050815a3ab1e180408bc4d9bcd0e86
libxl: allow guest to write "control/shutdown" xenstore node.

The PV shutdown/reboot/suspend protocol requires that the guest
acknowledge a request by clearing the node therefore it is necessary
to allow the guest to write to the node.

Currently libxl is quite relaxed about this protocol and doesn't
reeally seem to mind that the guest is unable to write the node to
perform the acknowledgement. However in a followup patch libxl needs
to be able to detect that a guest has acknowledged a suspend request.

A side effect of this change is that an empty "control/shutdown" node
is created upon domain creation instead of only being created when a
shutdown/reboot/suspend is requested. This should not (and does not
in my tests) have any negative impact on the guest.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Committed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
 tools/libxl/libxl_create.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -r 9280f1674705 -r c4b843d0b5f4 tools/libxl/libxl_create.c
--- a/tools/libxl/libxl_create.c        Fri Feb 11 17:53:08 2011 +0000
+++ b/tools/libxl/libxl_create.c        Fri Feb 11 17:56:24 2011 +0000
@@ -287,7 +287,7 @@ int libxl__domain_make(libxl_ctx *ctx, l
     libxl__gc gc = LIBXL_INIT_GC(ctx); /* fixme: should be done by caller */
     int flags, ret, i, rc;
     char *uuid_string;
-    char *rw_paths[] = { "device", "device/suspend/event-channel" , "data"};
+    char *rw_paths[] = { "control/shutdown", "device", 
"device/suspend/event-channel" , "data"};
     char *ro_paths[] = { "cpu", "memory", "device", "error", "drivers",
                          "control", "attr", "messages" };
     char *dom_path, *vm_path;

Xen-changelog mailing list

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] libxl: allow guest to write "control/shutdown" xenstore node., Xen patchbot-unstable <=