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: add pid path to libxl__spawner_sta

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] libxl: add pid path to libxl__spawner_starting
From: Xen patchbot-unstable <patchbot@xxxxxxx>
Date: Wed, 02 Nov 2011 22:00:13 +0000
Delivery-date: Wed, 02 Nov 2011 15:01:56 -0700
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 Olaf Hering <olaf@xxxxxxxxx>
# Date 1319707225 -7200
# Node ID 3235ee6505cd79287cff69fda6b2aed60c31b58a
# Parent  d577f5ae4986a2c1f3c4fd89162284c72b52573c
libxl: add pid path to libxl__spawner_starting

libxl_spawner_record_pid() should be able to write the pid to arbitrary paths.

v2:
 - use const char* for ->pid_path, and update comment

Signed-off-by: Olaf Hering <olaf@xxxxxxxxx>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
---


diff -r d577f5ae4986 -r 3235ee6505cd tools/libxl/libxl_dm.c
--- a/tools/libxl/libxl_dm.c    Thu Oct 27 11:19:22 2011 +0200
+++ b/tools/libxl/libxl_dm.c    Thu Oct 27 11:20:25 2011 +0200
@@ -848,6 +848,7 @@
 
     p->domid = info->domid;
     p->dom_path = libxl__xs_get_dompath(gc, info->domid);
+    p->pid_path = "image/device-model-pid";
     if (!p->dom_path) {
         rc = ERROR_FAIL;
         goto out_close;
diff -r d577f5ae4986 -r 3235ee6505cd tools/libxl/libxl_exec.c
--- a/tools/libxl/libxl_exec.c  Thu Oct 27 11:19:22 2011 +0200
+++ b/tools/libxl/libxl_exec.c  Thu Oct 27 11:20:25 2011 +0200
@@ -151,7 +151,7 @@
     char *path = NULL, *pid = NULL;
     int len;
 
-    if (asprintf(&path, "%s/%s", starting->dom_path, "image/device-model-pid") 
< 0)
+    if (asprintf(&path, "%s/%s", starting->dom_path, starting->pid_path) < 0)
         goto out;
 
     len = asprintf(&pid, "%d", innerchild);
diff -r d577f5ae4986 -r 3235ee6505cd tools/libxl/libxl_internal.h
--- a/tools/libxl/libxl_internal.h      Thu Oct 27 11:19:22 2011 +0200
+++ b/tools/libxl/libxl_internal.h      Thu Oct 27 11:20:25 2011 +0200
@@ -268,6 +268,7 @@
 
 typedef struct {
     char *dom_path; /* from libxl_malloc, only for libxl_spawner_record_pid */
+    const char *pid_path; /* only for libxl_spawner_record_pid */
     int domid;
     libxl__spawn_starting *for_spawn;
 } libxl__spawner_starting;

_______________________________________________
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: add pid path to libxl__spawner_starting, Xen patchbot-unstable <=