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-3.4-testing] blktap: fix blktapctrl abort

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-3.4-testing] blktap: fix blktapctrl abort
From: "Xen patchbot-3.4-testing" <patchbot-3.4-testing@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 29 Jan 2010 03:35:13 -0800
Delivery-date: Fri, 29 Jan 2010 03:35:10 -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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1264515673 0
# Node ID 3e79b92cf4eaee5b30a20a6b0a9509dd9c1648bb
# Parent  36159ea86bbd2b8ed240ee1a4795a9b544fafbeb
blktap: fix blktapctrl abort

On rebooting a hvm, the blktapctrl daemon has died.

gdb shows the following call trace:
(gdb) where
#0  0x00000039d1830155 in raise () from /lib64/libc.so.6
#1  0x00000039d1831bf0 in abort () from /lib64/libc.so.6
#2  0x00000039d186a38b in __libc_message () from /lib64/libc.so.6
#3  0x00000039d1871634 in _int_free () from /lib64/libc.so.6
#4  0x00000039d1874c5c in free () from /lib64/libc.so.6
#5  0x0000003320a01bdd in ueblktap_probe (h=3D0x6073b0,=20
    w=<value optimized out>, bepath_im=<value optimized out>) at
    xenbus.c:270
#6  0x0000003320a020e0 in xs_fire_next_watch (h=3D0x6073b0) at
xs_api.c:355
#7  0x0000000000401785 in main (argc=3D<value optimized out>,
    argv=<value optimized out>) at blktapctrl.c:907

There is a case that "/local/domain/0/backend/tap/<dom_id>" exists but
"/local/domain/<dom_id>/vm" is not in the xenstore.

Signed-off-by: Kouya Shimura <kouya@xxxxxxxxxxxxxx>
xen-unstable changeset:   20843:e1d61c5a008d
xen-unstable date:        Fri Jan 22 11:00:45 2010 +0000
---
 tools/blktap/lib/xenbus.c |    6 ++++++
 1 files changed, 6 insertions(+)

diff -r 36159ea86bbd -r 3e79b92cf4ea tools/blktap/lib/xenbus.c
--- a/tools/blktap/lib/xenbus.c Tue Jan 19 13:59:28 2010 +0000
+++ b/tools/blktap/lib/xenbus.c Tue Jan 26 14:21:13 2010 +0000
@@ -232,8 +232,11 @@ static int check_sharing(struct xs_handl
                        ret = -1;
                        break;
                }
+               cur_dom_uuid = NULL;
                xs_gather(h, path, "vm", NULL, &cur_dom_uuid, NULL);
                free(path);
+               if (!cur_dom_uuid)
+                       continue;
 
                if (!strcmp(cur_dom_uuid, dom_uuid)) {
                        free(cur_dom_uuid);
@@ -256,8 +259,11 @@ static int check_sharing(struct xs_handl
                                ret = -1;
                                break;
                        }
+                       params = NULL;
                        xs_gather(h, path, "params", NULL, &params, NULL);
                        free(path);
+                       if (!params)
+                               continue;
 
                        image_path[1] = get_image_path(params);
                        if (!strcmp(image_path[0], image_path[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-3.4-testing] blktap: fix blktapctrl abort, Xen patchbot-3.4-testing <=