From mboxrd@z Thu Jan 1 00:00:00 1970 From: Roger Pau Monne Subject: [PATCH v11 01/17] libxl: fix stubdom console destruction Date: Mon, 23 Jul 2012 18:27:29 +0100 Message-ID: <1343064465-17864-2-git-send-email-roger.pau@citrix.com> References: <1343064465-17864-1-git-send-email-roger.pau@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1343064465-17864-1-git-send-email-roger.pau@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xen.org Cc: Ian Jackson , Roger Pau Monne List-Id: xen-devel@lists.xenproject.org Stubdoms have several consoles attached, and they don't follow the xenstore protocol for devices, since they are always in state 1. We have to add an exception to libxl__initiate_device_remove, so libxl doesn't wait for them to reach state 6 (Closed). Report: http://markmail.org/message/yqgppcsdip6tnmh6 Cc: Ian Jackson Reported-by: Ian Campbell Signed-off-by: Roger Pau Monne --- tools/libxl/libxl_device.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/libxl/libxl_device.c b/tools/libxl/libxl_device.c index a94beab..c4392fa 100644 --- a/tools/libxl/libxl_device.c +++ b/tools/libxl/libxl_device.c @@ -592,8 +592,10 @@ void libxl__initiate_device_remove(libxl__egc *egc, LOG(ERROR, "unable to get info for domain %d", domid); goto out; } - if (QEMU_BACKEND(aodev->dev) && - (info.paused || info.dying || info.shutdown)) { + if ((QEMU_BACKEND(aodev->dev) && + (info.paused || info.dying || info.shutdown)) || + (libxl_is_stubdom(CTX, aodev->dev->domid, NULL) && + (aodev->dev->backend_kind == LIBXL__DEVICE_KIND_CONSOLE))) { /* * TODO: 4.2 Bodge due to QEMU, see comment on top of * libxl__initiate_device_remove in libxl_internal.h -- 1.7.7.5 (Apple Git-26)