if (l_disk->driverName) {
...
} else {
/* No driverName - default to raw/tap?? */
x_disk->format = LIBXL_DISK_FORMAT_RAW;
x_disk->backend = LIBXL_DISK_BACKEND_TAP;
}
I recall some discussion about the choice of these defaults, but can't
find anything in the xen or libvirt ml archives. We can adjust the
defaults (or defer to libxl?) if it makes sense. I took a quick peek at
newer libxl code (recall this was written against Xen 4.1 libxl) and
perhaps 'x_disk->backend = LIBXL_DISK_BACKEND_QDISK' would be a saner
default? Adding Ian to help with this question...
LIBXL_DISK_BACKEND_UNKNOWN will cause libxl to pick the best available
(which includes checking if blktap is actually there) backend given the
format and file type (block device, file etc). That's probably the right
default.
libxl__device_disk_set_backend is the guy to look at if you are
interested how the selection happens.
Ian.