[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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



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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.