[PATCH V2 0/3] Xen: Add support for qemu commandline passthrough

V2 of https://www.redhat.com/archives/libvir-list/2020-July/msg02043.html Changes in V2: - Drop use of virStringListCopy, and hence patch 1/4 - Switch to using 'xen' namespace and schema extenstion instead of qemu - Use more glib functions Jim Fehlig (3): Xen: Add support for qemu command-line passthrough Xen: Add support for qemu commandline passthrough to config converter news: Mention support for device model commandline passthrough in Xen NEWS.rst | 8 ++ docs/drvxen.html.in | 29 +++++++ docs/schemas/domaincommon.rng | 17 ++++ src/libxl/libxl_conf.c | 10 ++- src/libxl/libxl_conf.h | 8 ++ src/libxl/libxl_domain.c | 84 ++++++++++++++++++ src/libxl/libxl_domain.h | 1 + src/libxl/xen_xl.c | 91 ++++++++++++++++++++ tests/xlconfigdata/test-qemu-passthrough.cfg | 26 ++++++ tests/xlconfigdata/test-qemu-passthrough.xml | 53 ++++++++++++ tests/xlconfigtest.c | 1 + 11 files changed, 327 insertions(+), 1 deletion(-) create mode 100644 tests/xlconfigdata/test-qemu-passthrough.cfg create mode 100644 tests/xlconfigdata/test-qemu-passthrough.xml -- 2.26.2

Xen supports passing arbitrary arguments to the QEMU device model via the 'extra' member of the public libxl_domain_build_info structure. This patch adds a 'xen' namespace extension, similar to the QEMU and bhyve drivers, to map arbitrary arguments to the 'extra' member. Only passthrough of arguments is supported. Passthrough of environment variables or capabilities adjustments is not supported. Signed-off-by: Jim Fehlig <jfehlig@suse.com> --- docs/drvxen.html.in | 29 ++++++++++++ docs/schemas/domaincommon.rng | 17 +++++++ src/libxl/libxl_conf.c | 10 ++++- src/libxl/libxl_conf.h | 8 ++++ src/libxl/libxl_domain.c | 84 +++++++++++++++++++++++++++++++++++ src/libxl/libxl_domain.h | 1 + 6 files changed, 148 insertions(+), 1 deletion(-) diff --git a/docs/drvxen.html.in b/docs/drvxen.html.in index b2f41c1763..45a9329fcf 100644 --- a/docs/drvxen.html.in +++ b/docs/drvxen.html.in @@ -141,6 +141,35 @@ vnclisten = "0.0.0.0" disk = [ "tap:aio:/var/lib/xen/images/rhel5pv.img,xvda,w", "tap:qcow:/root/qcow1-xen.img,xvdd,w" ] vif = [ "mac=00:16:3e:60:36:ba,bridge=virbr0,script=vif-bridge,vifname=vif5.0" ]</pre> + <h2><a id="xencommand">Pass-through of arbitrary command-line arguments + to the qemu device model</a></h2> + + <p><span class="since">Since 6.7.0</span>, the Xen driver supports passing + arbitrary command-line arguments to the qemu device model used by Xen with + the <code><xen:commandline></code> element under <code>domain</code>. + In order to use command-line pass-through, an XML namespace request must be + issued that pulls in <code>http://libvirt.org/schemas/domain/xen/1.0</code>. + With the namespace in place, it is then possible to add + <code><xen:arg></code>sub-elements to + <code><xen:commandline></code> describing each argument passed to + the device model when starting the domain. + </p> + <p>The following example illustrates passing agruments to the QEMU device + model that define a floppy drive, which Xen does not support through its + public APIs: + </p> + <pre> +<domain type="xen" xmlns:xen="http://libvirt.org/schemas/domain/xen/1.0"> + ... + <xen:commandline> + <xen:arg value='-drive'/> + <xen:arg value='file=/path/to/image,format=raw,if=none,id=drive-fdc0-0-0'/> + <xen:arg value='-global'/> + <xen:arg value='isa-fdc.driveA=drive-fdc0-0-0'/> + </xen:commandline> +</domain> + </pre> + <h2><a id="xmlconfig">Example domain XML config</a></h2> <p> diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index 0d0dcbc5ce..7954696dce 100644 --- a/docs/schemas/domaincommon.rng +++ b/docs/schemas/domaincommon.rng @@ -87,6 +87,9 @@ <optional> <ref name='bhyvecmdline'/> </optional> + <optional> + <ref name='xencmdline'/> + </optional> </interleave> </element> </define> @@ -6799,6 +6802,20 @@ </element> </define> + <!-- + Optional hypervisor extensions in their own namespace: + Xen + --> + <define name="xencmdline"> + <element name="commandline" ns="http://libvirt.org/schemas/domain/xen/1.0"> + <zeroOrMore> + <element name="arg"> + <attribute name='value'/> + </element> + </zeroOrMore> + </element> + </define> + <!-- Type library --> diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c index 7c2c015015..e7c7022b69 100644 --- a/src/libxl/libxl_conf.c +++ b/src/libxl/libxl_conf.c @@ -760,6 +760,13 @@ libxlMakeDomBuildInfo(virDomainDefPtr def, libxl_get_required_shadow_memory(b_info->max_memkb, b_info->max_vcpus); + if (def->namespaceData) { + libxlDomainXmlNsDefPtr nsdata = def->namespaceData; + + if (nsdata->num_args > 0) + b_info->extra = g_strdupv(nsdata->args); + } + return 0; } @@ -2513,5 +2520,6 @@ libxlCreateXMLConf(libxlDriverPrivatePtr driver) libxlDomainDefParserConfig.priv = driver; return virDomainXMLOptionNew(&libxlDomainDefParserConfig, &libxlDomainXMLPrivateDataCallbacks, - NULL, NULL, NULL); + &libxlDriverDomainXMLNamespace, + NULL, NULL); } diff --git a/src/libxl/libxl_conf.h b/src/libxl/libxl_conf.h index b057a9e4ba..fc652df61e 100644 --- a/src/libxl/libxl_conf.h +++ b/src/libxl/libxl_conf.h @@ -168,6 +168,14 @@ struct _libxlSavefileHeader { uint32_t unused[10]; }; + +typedef struct _libxlDomainXmlNsDef libxlDomainXmlNsDef; +typedef libxlDomainXmlNsDef *libxlDomainXmlNsDefPtr; +struct _libxlDomainXmlNsDef { + size_t num_args; + char **args; +}; + libxlDriverConfigPtr libxlDriverConfigNew(void); int diff --git a/src/libxl/libxl_domain.c b/src/libxl/libxl_domain.c index d9fcde4364..f6bc8211b3 100644 --- a/src/libxl/libxl_domain.c +++ b/src/libxl/libxl_domain.c @@ -1573,3 +1573,87 @@ libxlDomainDefCheckABIStability(libxlDriverPrivatePtr driver, virDomainDefFree(migratableDefDst); return ret; } + + +static void +libxlDomainDefNamespaceFree(void *nsdata) +{ + libxlDomainXmlNsDefPtr def = nsdata; + + if (!def) + return; + + g_strfreev(def->args); + g_free(def); +} + + +static int +libxlDomainDefNamespaceParse(xmlXPathContextPtr ctxt, + void **data) +{ + libxlDomainXmlNsDefPtr nsdata = NULL; + g_autofree xmlNodePtr *nodes = NULL; + ssize_t nnodes; + size_t i; + int ret = -1; + + if ((nnodes = virXPathNodeSet("./xen:commandline/xen:arg", ctxt, &nodes)) < 0) + return -1; + + if (nnodes == 0) + return 0; + + nsdata = g_new0(libxlDomainXmlNsDef, 1); + nsdata->args = g_new0(char *, nnodes + 1); + + for (i = 0; i < nnodes; i++) { + if (!(nsdata->args[nsdata->num_args++] = virXMLPropString(nodes[i], "value"))) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("No device model command-line argument specified")); + goto cleanup; + } + } + + if (nsdata->num_args > 0) + *data = g_steal_pointer(&nsdata); + + ret = 0; + + cleanup: + libxlDomainDefNamespaceFree(nsdata); + return ret; +} + + +static int +libxlDomainDefNamespaceFormatXML(virBufferPtr buf, + void *nsdata) +{ + libxlDomainXmlNsDefPtr cmd = nsdata; + size_t i; + + if (!cmd->num_args) + return 0; + + virBufferAddLit(buf, "<xen:commandline>\n"); + virBufferAdjustIndent(buf, 2); + + for (i = 0; i < cmd->num_args; i++) + virBufferEscapeString(buf, "<xen:arg value='%s'/>\n", + cmd->args[i]); + + virBufferAdjustIndent(buf, -2); + virBufferAddLit(buf, "</xen:commandline>\n"); + + return 0; +} + + +virXMLNamespace libxlDriverDomainXMLNamespace = { + .parse = libxlDomainDefNamespaceParse, + .free = libxlDomainDefNamespaceFree, + .format = libxlDomainDefNamespaceFormatXML, + .prefix = "xen", + .uri = "http://libvirt.org/schemas/domain/xen/1.0", +}; diff --git a/src/libxl/libxl_domain.h b/src/libxl/libxl_domain.h index 7e28093722..00682546e0 100644 --- a/src/libxl/libxl_domain.h +++ b/src/libxl/libxl_domain.h @@ -77,6 +77,7 @@ struct _libxlDomainObjPrivate { extern virDomainXMLPrivateDataCallbacks libxlDomainXMLPrivateDataCallbacks; extern virDomainDefParserConfig libxlDomainDefParserConfig; +extern virXMLNamespace libxlDriverDomainXMLNamespace; extern const struct libxl_event_hooks ev_hooks; int -- 2.26.2

On 8/5/20 12:13 AM, Jim Fehlig wrote:
Xen supports passing arbitrary arguments to the QEMU device model via the 'extra' member of the public libxl_domain_build_info structure. This patch adds a 'xen' namespace extension, similar to the QEMU and bhyve drivers, to map arbitrary arguments to the 'extra' member. Only passthrough of arguments is supported. Passthrough of environment variables or capabilities adjustments is not supported.
Signed-off-by: Jim Fehlig <jfehlig@suse.com> --- docs/drvxen.html.in | 29 ++++++++++++ docs/schemas/domaincommon.rng | 17 +++++++ src/libxl/libxl_conf.c | 10 ++++- src/libxl/libxl_conf.h | 8 ++++ src/libxl/libxl_domain.c | 84 +++++++++++++++++++++++++++++++++++ src/libxl/libxl_domain.h | 1 + 6 files changed, 148 insertions(+), 1 deletion(-)
diff --git a/src/libxl/libxl_domain.c b/src/libxl/libxl_domain.c index d9fcde4364..f6bc8211b3 100644 --- a/src/libxl/libxl_domain.c +++ b/src/libxl/libxl_domain.c
+static int +libxlDomainDefNamespaceParse(xmlXPathContextPtr ctxt, + void **data) +{ + libxlDomainXmlNsDefPtr nsdata = NULL; + g_autofree xmlNodePtr *nodes = NULL; + ssize_t nnodes; + size_t i; + int ret = -1; + + if ((nnodes = virXPathNodeSet("./xen:commandline/xen:arg", ctxt, &nodes)) < 0) + return -1; + + if (nnodes == 0) + return 0; + + nsdata = g_new0(libxlDomainXmlNsDef, 1); + nsdata->args = g_new0(char *, nnodes + 1); + + for (i = 0; i < nnodes; i++) { + if (!(nsdata->args[nsdata->num_args++] = virXMLPropString(nodes[i], "value"))) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("No device model command-line argument specified")); + goto cleanup; + } + } + + if (nsdata->num_args > 0) + *data = g_steal_pointer(&nsdata);
This if () looks redundant to me. The for-loop above in combination with nnodes = 0 check ensures that num_args is greater than zero here.
+ + ret = 0; + + cleanup: + libxlDomainDefNamespaceFree(nsdata); + return ret; +} +
Michal

On 8/25/20 9:15 AM, Michal Privoznik wrote:
On 8/5/20 12:13 AM, Jim Fehlig wrote:
Xen supports passing arbitrary arguments to the QEMU device model via the 'extra' member of the public libxl_domain_build_info structure. This patch adds a 'xen' namespace extension, similar to the QEMU and bhyve drivers, to map arbitrary arguments to the 'extra' member. Only passthrough of arguments is supported. Passthrough of environment variables or capabilities adjustments is not supported.
Signed-off-by: Jim Fehlig <jfehlig@suse.com> --- docs/drvxen.html.in | 29 ++++++++++++ docs/schemas/domaincommon.rng | 17 +++++++ src/libxl/libxl_conf.c | 10 ++++- src/libxl/libxl_conf.h | 8 ++++ src/libxl/libxl_domain.c | 84 +++++++++++++++++++++++++++++++++++ src/libxl/libxl_domain.h | 1 + 6 files changed, 148 insertions(+), 1 deletion(-)
diff --git a/src/libxl/libxl_domain.c b/src/libxl/libxl_domain.c index d9fcde4364..f6bc8211b3 100644 --- a/src/libxl/libxl_domain.c +++ b/src/libxl/libxl_domain.c
+static int +libxlDomainDefNamespaceParse(xmlXPathContextPtr ctxt, + void **data) +{ + libxlDomainXmlNsDefPtr nsdata = NULL; + g_autofree xmlNodePtr *nodes = NULL; + ssize_t nnodes; + size_t i; + int ret = -1; + + if ((nnodes = virXPathNodeSet("./xen:commandline/xen:arg", ctxt, &nodes)) < 0) + return -1; + + if (nnodes == 0) + return 0; + + nsdata = g_new0(libxlDomainXmlNsDef, 1); + nsdata->args = g_new0(char *, nnodes + 1); + + for (i = 0; i < nnodes; i++) { + if (!(nsdata->args[nsdata->num_args++] = virXMLPropString(nodes[i], "value"))) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("No device model command-line argument specified")); + goto cleanup; + } + } + + if (nsdata->num_args > 0) + *data = g_steal_pointer(&nsdata);
This if () looks redundant to me. The for-loop above in combination with nnodes = 0 check ensures that num_args is greater than zero here.
Yes, good point. I'll remove it before pushing. Thanks a lot for reviewing the series! Regards, Jim

Support qemu commandline passthrough in the domXML to native config converter. Add tests to check the conversion. Signed-off-by: Jim Fehlig <jfehlig@suse.com> --- src/libxl/xen_xl.c | 91 ++++++++++++++++++++ tests/xlconfigdata/test-qemu-passthrough.cfg | 26 ++++++ tests/xlconfigdata/test-qemu-passthrough.xml | 53 ++++++++++++ tests/xlconfigtest.c | 1 + 4 files changed, 171 insertions(+) diff --git a/src/libxl/xen_xl.c b/src/libxl/xen_xl.c index c6aac16de5..258aca5c73 100644 --- a/src/libxl/xen_xl.c +++ b/src/libxl/xen_xl.c @@ -32,6 +32,7 @@ #include "virstoragefile.h" #include "xen_xl.h" #include "libxl_capabilities.h" +#include "libxl_conf.h" #include "cpu/cpu.h" #define VIR_FROM_THIS VIR_FROM_XENXL @@ -1158,6 +1159,42 @@ xenParseXLChannel(virConfPtr conf, virDomainDefPtr def) return -1; } +static int +xenParseXLNamespaceData(virConfPtr conf, virDomainDefPtr def) +{ + virConfValuePtr list = virConfGetValue(conf, "device_model_args"); + VIR_AUTOSTRINGLIST args = NULL; + size_t nargs; + libxlDomainXmlNsDefPtr nsdata = NULL; + + if (list && list->type == VIR_CONF_LIST) { + list = list->list; + while (list) { + if ((list->type != VIR_CONF_STRING) || (list->str == NULL)) { + list = list->next; + continue; + } + + virStringListAdd(&args, list->str); + list = list->next; + } + } + + if (!args) + return 0; + + nargs = g_strv_length(args); + if (nargs > 0) { + nsdata = g_new0(libxlDomainXmlNsDef, 1); + + nsdata->args = g_steal_pointer(&args); + nsdata->num_args = nargs; + def->namespaceData = nsdata; + } + + return 0; +} + virDomainDefPtr xenParseXL(virConfPtr conf, virCapsPtr caps, @@ -1170,6 +1207,7 @@ xenParseXL(virConfPtr conf, def->virtType = VIR_DOMAIN_VIRT_XEN; def->id = -1; + def->ns = *(virDomainXMLOptionGetNamespace(xmlopt)); if (xenParseConfigCommon(conf, def, caps, XEN_CONFIG_FORMAT_XL, xmlopt) < 0) @@ -1207,6 +1245,9 @@ xenParseXL(virConfPtr conf, if (xenParseXLChannel(conf, def) < 0) goto cleanup; + if (xenParseXLNamespaceData(conf, def) < 0) + goto cleanup; + if (virDomainDefPostParse(def, VIR_DOMAIN_DEF_PARSE_ABI_UPDATE, xmlopt, NULL) < 0) goto cleanup; @@ -2165,6 +2206,53 @@ xenFormatXLDomainChannels(virConfPtr conf, virDomainDefPtr def) return -1; } +static int +xenFormatXLDomainNamespaceData(virConfPtr conf, virDomainDefPtr def) +{ + libxlDomainXmlNsDefPtr nsdata = def->namespaceData; + virConfValuePtr args = NULL; + size_t i; + + if (!nsdata) + return 0; + + if (nsdata->num_args == 0) + return 0; + + if (VIR_ALLOC(args) < 0) + return -1; + + args->type = VIR_CONF_LIST; + args->list = NULL; + + for (i = 0; i < nsdata->num_args; i++) { + virConfValuePtr val, tmp; + + if (VIR_ALLOC(val) < 0) + goto error; + + val->type = VIR_CONF_STRING; + val->str = g_strdup(nsdata->args[i]); + tmp = args->list; + while (tmp && tmp->next) + tmp = tmp->next; + if (tmp) + tmp->next = val; + else + args->list = val; + } + + if (args->list != NULL) + if (virConfSetValue(conf, "device_model_args", args) < 0) + goto error; + + return 0; + + error: + virConfFreeValue(args); + return -1; +} + virConfPtr xenFormatXL(virDomainDefPtr def, virConnectPtr conn) { @@ -2208,5 +2296,8 @@ xenFormatXL(virDomainDefPtr def, virConnectPtr conn) if (xenFormatXLDomainChannels(conf, def) < 0) return NULL; + if (xenFormatXLDomainNamespaceData(conf, def) < 0) + return NULL; + return g_steal_pointer(&conf); } diff --git a/tests/xlconfigdata/test-qemu-passthrough.cfg b/tests/xlconfigdata/test-qemu-passthrough.cfg new file mode 100644 index 0000000000..42aad92205 --- /dev/null +++ b/tests/xlconfigdata/test-qemu-passthrough.cfg @@ -0,0 +1,26 @@ +name = "XenGuest2" +uuid = "c7a5fdb2-cdaf-9455-926a-d65c16db1809" +maxmem = 579 +memory = 394 +vcpus = 1 +pae = 1 +acpi = 1 +apic = 1 +viridian = 0 +rtc_timeoffset = 0 +localtime = 0 +on_poweroff = "destroy" +on_reboot = "restart" +on_crash = "restart" +device_model = "/usr/lib/xen/bin/qemu-system-i386" +sdl = 0 +vnc = 1 +vncunused = 1 +vnclisten = "127.0.0.1" +vif = [ "mac=00:16:3e:66:92:9c,bridge=xenbr1,script=vif-bridge,model=e1000" ] +parallel = "none" +serial = "none" +builder = "hvm" +boot = "d" +disk = [ "format=raw,vdev=hda,access=rw,backendtype=qdisk,target=/var/lib/libvirt/images/XenGuest2" ] +device_model_args = [ "-debugcon", "file:/tmp/debug.log", "-global", "isa-debugcon.iobase=0x402" ] diff --git a/tests/xlconfigdata/test-qemu-passthrough.xml b/tests/xlconfigdata/test-qemu-passthrough.xml new file mode 100644 index 0000000000..5de35143c0 --- /dev/null +++ b/tests/xlconfigdata/test-qemu-passthrough.xml @@ -0,0 +1,53 @@ +<domain type='xen' xmlns:xen='http://libvirt.org/schemas/domain/xen/1.0'> + <name>XenGuest2</name> + <uuid>c7a5fdb2-cdaf-9455-926a-d65c16db1809</uuid> + <memory unit='KiB'>592896</memory> + <currentMemory unit='KiB'>403456</currentMemory> + <vcpu placement='static'>1</vcpu> + <os> + <type arch='x86_64' machine='xenfv'>hvm</type> + <loader type='rom'>/usr/lib/xen/boot/hvmloader</loader> + <boot dev='cdrom'/> + </os> + <features> + <acpi/> + <apic/> + <pae/> + </features> + <clock offset='variable' adjustment='0' basis='utc'/> + <on_poweroff>destroy</on_poweroff> + <on_reboot>restart</on_reboot> + <on_crash>restart</on_crash> + <devices> + <emulator>/usr/lib/xen/bin/qemu-system-i386</emulator> + <disk type='file' device='disk'> + <driver name='qemu' type='raw'/> + <source file='/var/lib/libvirt/images/XenGuest2'/> + <target dev='hda' bus='ide'/> + <address type='drive' controller='0' bus='0' target='0' unit='0'/> + </disk> + <controller type='xenbus' index='0'/> + <controller type='ide' index='0'/> + <interface type='bridge'> + <mac address='00:16:3e:66:92:9c'/> + <source bridge='xenbr1'/> + <script path='vif-bridge'/> + <model type='e1000'/> + </interface> + <input type='mouse' bus='ps2'/> + <input type='keyboard' bus='ps2'/> + <graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1'> + <listen type='address' address='127.0.0.1'/> + </graphics> + <video> + <model type='cirrus' vram='8192' heads='1' primary='yes'/> + </video> + <memballoon model='xen'/> + </devices> + <xen:commandline> + <xen:arg value='-debugcon'/> + <xen:arg value='file:/tmp/debug.log'/> + <xen:arg value='-global'/> + <xen:arg value='isa-debugcon.iobase=0x402'/> + </xen:commandline> +</domain> diff --git a/tests/xlconfigtest.c b/tests/xlconfigtest.c index b2e045dfa5..b606164742 100644 --- a/tests/xlconfigtest.c +++ b/tests/xlconfigtest.c @@ -304,6 +304,7 @@ mymain(void) #ifdef LIBXL_HAVE_CREATEINFO_PASSTHROUGH DO_TEST("fullvirt-hypervisor-features"); #endif + DO_TEST("qemu-passthrough"); testXLFreeDriver(driver); -- 2.26.2

Signed-off-by: Jim Fehlig <jfehlig@suse.com> --- NEWS.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/NEWS.rst b/NEWS.rst index 63ca689b43..9aa6d122b6 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -13,6 +13,13 @@ v6.7.0 (unreleased) * **New features** + * xen: Add support for device model command-line passthrough + + Xen supports passing arbitrary arguments to the QEMU device model using + the ``device_model_args`` setting in xl.cfg(5). The libvirt xen driver now + supports this using ``<xen:commandline/>`` XML extensions. + + * **Improvements** * **Bug fixes** @@ -40,6 +47,7 @@ v6.6.0 (2020-08-02) management applications may wish to override this behaviour. This is now possible via new ``cow`` element. + * **Improvements** * esx: Change the NIC limit for recent virtualHW versions -- 2.26.2

Hi All, Any comments on V2 of this series? (Thanks Jano for reviewing V1!) Regards, Jim On 8/4/20 4:13 PM, Jim Fehlig wrote:
V2 of https://www.redhat.com/archives/libvir-list/2020-July/msg02043.html
Changes in V2: - Drop use of virStringListCopy, and hence patch 1/4
- Switch to using 'xen' namespace and schema extenstion instead of qemu
- Use more glib functions
Jim Fehlig (3): Xen: Add support for qemu command-line passthrough Xen: Add support for qemu commandline passthrough to config converter news: Mention support for device model commandline passthrough in Xen
NEWS.rst | 8 ++ docs/drvxen.html.in | 29 +++++++ docs/schemas/domaincommon.rng | 17 ++++ src/libxl/libxl_conf.c | 10 ++- src/libxl/libxl_conf.h | 8 ++ src/libxl/libxl_domain.c | 84 ++++++++++++++++++ src/libxl/libxl_domain.h | 1 + src/libxl/xen_xl.c | 91 ++++++++++++++++++++ tests/xlconfigdata/test-qemu-passthrough.cfg | 26 ++++++ tests/xlconfigdata/test-qemu-passthrough.xml | 53 ++++++++++++ tests/xlconfigtest.c | 1 + 11 files changed, 327 insertions(+), 1 deletion(-) create mode 100644 tests/xlconfigdata/test-qemu-passthrough.cfg create mode 100644 tests/xlconfigdata/test-qemu-passthrough.xml

On 8/5/20 12:13 AM, Jim Fehlig wrote:
V2 of https://www.redhat.com/archives/libvir-list/2020-July/msg02043.html
Changes in V2: - Drop use of virStringListCopy, and hence patch 1/4
- Switch to using 'xen' namespace and schema extenstion instead of qemu
- Use more glib functions
Jim Fehlig (3): Xen: Add support for qemu command-line passthrough Xen: Add support for qemu commandline passthrough to config converter news: Mention support for device model commandline passthrough in Xen
NEWS.rst | 8 ++ docs/drvxen.html.in | 29 +++++++ docs/schemas/domaincommon.rng | 17 ++++ src/libxl/libxl_conf.c | 10 ++- src/libxl/libxl_conf.h | 8 ++ src/libxl/libxl_domain.c | 84 ++++++++++++++++++ src/libxl/libxl_domain.h | 1 + src/libxl/xen_xl.c | 91 ++++++++++++++++++++ tests/xlconfigdata/test-qemu-passthrough.cfg | 26 ++++++ tests/xlconfigdata/test-qemu-passthrough.xml | 53 ++++++++++++ tests/xlconfigtest.c | 1 + 11 files changed, 327 insertions(+), 1 deletion(-) create mode 100644 tests/xlconfigdata/test-qemu-passthrough.cfg create mode 100644 tests/xlconfigdata/test-qemu-passthrough.xml
Reviewed-by: Michal Privoznik <mprivozn@redhat.com> Michal
participants (2)
-
Jim Fehlig
-
Michal Privoznik