diff options
author | George Dunlap <george.dunlap@eu.citrix.com> | 2013-04-02 14:11:33 +0000 |
---|---|---|
committer | Ian Jackson <Ian.Jackson@eu.citrix.com> | 2013-04-08 18:00:29 +0100 |
commit | ac16730d0339d41fd7d129a5cb2d40ed67a303d9 (patch) | |
tree | d167d3b1e09737a3a6341fa44500a424384ddca5 /tools/libxl/libxl_types.idl | |
parent | 0e6086a7de36e539d54eb82e61cf94e7f5363c02 (diff) | |
download | xen-ac16730d0339d41fd7d129a5cb2d40ed67a303d9.tar.gz xen-ac16730d0339d41fd7d129a5cb2d40ed67a303d9.tar.bz2 xen-ac16730d0339d41fd7d129a5cb2d40ed67a303d9.zip |
libxl: Allow multiple USB devices on HVM domain creation
This patch allows an HVM domain to be created with multiple USB
devices.
Since the previous interface only allowed the passing of a single
device, this requires us to add a new element to the hvm struct of
libxl_domain_build_info -- usbdevice_list. For API compatibility, the
old element, usbdevice, remains.
If hvm.usbdevice_list is set, each device listed will cause an extra
"-usbdevice [foo]" to be appended to the qemu command line.
Callers may set either hvm.usbdevice or hvm.usbdevice_list, but not
both; libxl will throw an error if both are set.
In order to allow users of libxl to write software compatible with
older versions of libxl, also define LIBXL_HAVE_BUILDINFO_USBDEVICE_LIST.
If this is defined, callers may use either hvm.usbdevice or
hvm.usbdevice_list; otherwise, only hvm.usbdevice will be available.
as applied:
- Fix whitespace errors -iwj
v3:
- Duplicate functionality in both "new" and "old", since we're not
unifying the two anymore.
v2:
- Throw an error if both usbdevice and usbdevice_list are set
- Update and clarify definition based on feedback
- Previous patches means this works for both traditional and upstream
Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/libxl/libxl_types.idl')
-rw-r--r-- | tools/libxl/libxl_types.idl | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/libxl/libxl_types.idl b/tools/libxl/libxl_types.idl index f3c212bc8c..6cb6de613c 100644 --- a/tools/libxl/libxl_types.idl +++ b/tools/libxl/libxl_types.idl @@ -330,6 +330,7 @@ libxl_domain_build_info = Struct("domain_build_info",[ ("usbdevice", string), ("soundhw", string), ("xen_platform_pci", libxl_defbool), + ("usbdevice_list", libxl_string_list), ])), ("pv", Struct(None, [("kernel", string), ("slack_memkb", MemKB), |