This is mostly an excuse to add a _get_supported_devices() method
used in fallback cases (when the deployment does not specify
a disk driver to be used) as this will be useful later.
The list of supported devices is generated with
- devices supported both by the OS and the platform (hypervisor)
- devices for which we have a OS driver, and which are supported
by the platform
When doing this work, I realized a few things were missing
from libosinfo:
- to properly guess the bus to use for a disk (sata, ide,
scsi, ...) from a libosinfo device, we'd need to have the
PCI subclass in libosinfo. This will probably need to be
added at some point
- something that would be nice for easier fallback when the
deployment does not specify a device would be a way for
OS/platforms to indicate that their preferred disk device
is virtio-disk, then sata device XXX, ...
I also think deployments would be more flexible if a deployment
meant for qemu-1.2.0 could be used with qemu-1.3.0. Currently,
osinfo_db_find_deployment does not follow 'upgrades' relations
on platforms, but I think it would be more convenient if it did.
Christophe