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-devel

[Xen-devel] [PATCH 6 of 6] libxl: probe disk backend type in libxl_devic

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH 6 of 6] libxl: probe disk backend type in libxl_device_disk_add
From: Ian Campbell <ian.campbell@xxxxxxxxxx>
Date: Thu, 29 Sep 2011 17:20:33 +0100
Cc: Ian Campbell <ian.campbell@xxxxxxxxxx>
Delivery-date: Thu, 29 Sep 2011 09:25:41 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <patchbomb.1317313227@xxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <patchbomb.1317313227@xxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mercurial-patchbomb/1.6.4
# HG changeset patch
# User Ian Campbell <ian.campbell@xxxxxxxxxx>
# Date 1317313222 -3600
# Node ID 966d33c61d0b1dcf8545253b198e185c3757bc65
# Parent  50cd0fd187b39a263680d8a4b4f1a8511c7c04ee
libxl: probe disk backend type in libxl_device_disk_add

Without this "xl block-attach" does not work. On create do_domain_create already
catches this.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

diff -r 50cd0fd187b3 -r 966d33c61d0b tools/libxl/libxl.c
--- a/tools/libxl/libxl.c       Thu Sep 29 17:17:14 2011 +0100
+++ b/tools/libxl/libxl.c       Thu Sep 29 17:20:22 2011 +0100
@@ -926,6 +926,9 @@ int libxl_device_disk_add(libxl_ctx *ctx
     libxl__device device;
     int major, minor, rc;
 
+    rc = libxl__device_disk_set_backend(&gc, disk);
+    if (rc) goto out;
+
     front = flexarray_make(16, 1);
     if (!front) {
         rc = ERROR_NOMEM;

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel