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

Re: [Xen-devel] [PATCH V2] Add libxenlight driver

To: Jim Fehlig <jfehlig@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH V2] Add libxenlight driver
From: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Date: Fri, 25 Feb 2011 17:52:07 +0000
Cc: "libvir-list@xxxxxxxxxx" <libvir-list@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, "gross@xxxxxxxxxxxxx" <gross@xxxxxxxxxxxxx>
Delivery-date: Fri, 25 Feb 2011 09:52:31 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1298429765-24170-1-git-send-email-jfehlig@xxxxxxxxxx>
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: <1298429765-24170-1-git-send-email-jfehlig@xxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Alpine 2.00 (DEB 1167 2008-08-23)
On Wed, 23 Feb 2011, Jim Fehlig wrote:
> Add a new xen driver based on libxenlight [1], which is the primary
> toolstack starting with Xen 4.1.0.  The driver is stateful, runs
> privileged only, and is accessed with libxl:/// URI.
> 
> V2:
>   - Update to Xen 4.1 RC6-pre (c/s 22940:5a4710640f81)
>   - Rebased to current master
>   - Plug memory leaks found by Stefano Stabellini and valgrind
>   - Handle SHUTDOWN_crash domain death event

It looks good to me.


> +        if (l_disks[i]->driverName) {
> +            if (STREQ(l_disks[i]->driverName, "tap") ||
> +                STREQ(l_disks[i]->driverName, "tap2")) {
> +                if (l_disks[i]->driverType) {
> +                    if (STREQ(l_disks[i]->driverType, "qcow")) {
> +                        x_disks[i].format = DISK_FORMAT_QCOW;
> +                        x_disks[i].backend = DISK_BACKEND_QDISK;
> +                    } else if (STREQ(l_disks[i]->driverType, "qcow2")) {
> +                        x_disks[i].format = DISK_FORMAT_QCOW2;
> +                        x_disks[i].backend = DISK_BACKEND_QDISK;
> +                    } else if (STREQ(l_disks[i]->driverType, "vhd")) {
> +                        x_disks[i].format = DISK_FORMAT_VHD;
> +                        x_disks[i].backend = DISK_BACKEND_TAP;
> +                    } else if (STREQ(l_disks[i]->driverType, "aio") ||
> +                               STREQ(l_disks[i]->driverType, "raw")) {
> +                        x_disks[i].format = DISK_FORMAT_RAW;
> +                        x_disks[i].backend = DISK_BACKEND_TAP;
> +                    }

This is more a question about libvirt than this specific driver, but I
think "aio" shouldn't be considered a "driverType", in fact you can
have:

tap:aio:qcow:/path/to/file

I realize that it is crazy and if "aio" is an implementation detail it
shouldn't be exposed to the user but I am not the one that introduced
this syntax, I am actually looking forward to removing it completely.
In xl we currently just ignore "aio" and carry on parsing the other
fields.

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

<Prev in Thread] Current Thread [Next in Thread>