[PATCH for 7.0.0 v1 00/26] Introduce virtio memory support
by Michal Privoznik
Available also here:
https://gitlab.com/MichalPrivoznik/libvirt/-/commits/virtio_mem/
There are new virtio variants of pc-dimm and nvdimm devices. This is the
first attempt to impalement support for them in libvirt.
Thanks to David Hildenbrand for his valuable input!
Michal Prívozník (26):
viruuid: Rework virUUIDIsValid()
internal.h: Introduce VIR_IS_POW2()
docs: Fix nvdimm example wrt to <uuid/>
domain_conf: Check NVDIMM UUID in ABI stability
qemu_domain_address: Reformat qemuDomainAssignS390Addresses()
conf: Require nvdimm path in validate step
domain_conf: Fix virDomainMemoryModel type
virDomainMemorySourceDefFormat: Utilize virXMLFormatElement()
virDomainMemoryTargetDefFormat: Utilize virXMLFormatElement()
qemu: Move mem validation into post parse validator
conf: Move some of virDomainMemoryDef members into a union
conf: Introduce virtio-pmem <memory/> model
qemu_capabilities: Introduce QEMU_CAPS_DEVICE_VIRTIO_{P}MEM_PCI
qemu_validate: Require virtio-mem device for mem model virtio
security: Relabel virtio mem
qemu: Allow virtio-pmem in CGroups
qemu: Create virtio-pmem in domain namespace
qemu_command: Move dimm into qemuBuildDeviceAddressStr()
qemu: Build command line for virtio-pmem
conf: Introduce virtio-mem <memory/> model
qemu: Build command line for virtio-mem
qemu: Wire up <memory/> live update
qemu: Wire up MEMORY_DEVICE_SIZE_CHANGE event
qemu: Refresh the actual size of virtio-mem on monitor reconnect
virsh: Simplify @flags handing in cmdSetmem() and cmdSetmaxmem()
virsh: Introduce --virtio to setmem
docs/formatdomain.rst | 70 +++-
docs/schemas/domaincommon.rng | 16 +
src/conf/domain_conf.c | 372 ++++++++++++++----
src/conf/domain_conf.h | 38 +-
src/internal.h | 10 +
src/libvirt_private.syms | 2 +
src/qemu/qemu_alias.c | 59 ++-
src/qemu/qemu_capabilities.c | 4 +
src/qemu/qemu_capabilities.h | 2 +
src/qemu/qemu_cgroup.c | 43 +-
src/qemu/qemu_command.c | 172 +++++---
src/qemu/qemu_command.h | 5 +-
src/qemu/qemu_domain.c | 99 +++--
src/qemu/qemu_domain.h | 1 +
src/qemu/qemu_domain_address.c | 98 +++--
src/qemu/qemu_domain_address.h | 3 +-
src/qemu/qemu_driver.c | 198 +++++++++-
src/qemu/qemu_hotplug.c | 22 +-
src/qemu/qemu_hotplug.h | 5 +
src/qemu/qemu_monitor.c | 37 ++
src/qemu/qemu_monitor.h | 27 ++
src/qemu/qemu_monitor_json.c | 94 +++--
src/qemu/qemu_monitor_json.h | 5 +
src/qemu/qemu_namespace.c | 19 +-
src/qemu/qemu_process.c | 52 ++-
src/qemu/qemu_validate.c | 78 ++--
src/security/security_apparmor.c | 35 +-
src/security/security_dac.c | 48 ++-
src/security/security_selinux.c | 48 ++-
src/security/virt-aa-helper.c | 22 +-
src/util/virrandom.c | 2 +-
src/util/viruuid.c | 17 +-
src/util/viruuid.h | 2 +-
.../caps_4.1.0.x86_64.xml | 1 +
.../caps_4.2.0.x86_64.xml | 1 +
.../caps_5.0.0.x86_64.xml | 1 +
.../caps_5.1.0.x86_64.xml | 2 +
.../caps_5.2.0.x86_64.xml | 2 +
...mory-hotplug-virtio-mem.x86_64-latest.args | 53 +++
.../memory-hotplug-virtio-mem.xml | 78 ++++
...ory-hotplug-virtio-pmem.x86_64-latest.args | 45 +++
.../memory-hotplug-virtio-pmem.xml | 54 +++
tests/qemuxml2argvtest.c | 2 +
...emory-hotplug-virtio-mem.x86_64-latest.xml | 1 +
...mory-hotplug-virtio-pmem.x86_64-latest.xml | 1 +
tests/qemuxml2xmltest.c | 3 +
tools/virsh-domain.c | 138 ++++++-
47 files changed, 1703 insertions(+), 384 deletions(-)
create mode 100644 tests/qemuxml2argvdata/memory-hotplug-virtio-mem.x86_64-latest.args
create mode 100644 tests/qemuxml2argvdata/memory-hotplug-virtio-mem.xml
create mode 100644 tests/qemuxml2argvdata/memory-hotplug-virtio-pmem.x86_64-latest.args
create mode 100644 tests/qemuxml2argvdata/memory-hotplug-virtio-pmem.xml
create mode 120000 tests/qemuxml2xmloutdata/memory-hotplug-virtio-mem.x86_64-latest.xml
create mode 120000 tests/qemuxml2xmloutdata/memory-hotplug-virtio-pmem.x86_64-latest.xml
--
2.26.2
3 years, 11 months
[PATCH] target/ppc: Remove "compat" property of server class POWER CPUs
by Greg Kurz
This property has been deprecated since QEMU 5.0 by commit 22062e54bb68.
We only kept a legacy hack that internally converts "compat" into the
official "max-cpu-compat" property of the pseries machine type.
According to our deprecation policy, we could have removed it for QEMU 5.2
already. Do it now ; since ppc_cpu_parse_featurestr() now just calls the
generic parent_parse_features handler, drop it as well.
Users are supposed to use the "max-cpu-compat" property of the pseries
machine type instead.
Signed-off-by: Greg Kurz <groug(a)kaod.org>
---
docs/system/deprecated.rst | 7 ----
target/ppc/translate_init.c.inc | 59 ---------------------------------
2 files changed, 66 deletions(-)
diff --git a/docs/system/deprecated.rst b/docs/system/deprecated.rst
index 565389697e84..09c8f380bc82 100644
--- a/docs/system/deprecated.rst
+++ b/docs/system/deprecated.rst
@@ -281,13 +281,6 @@ a future version of QEMU. It's unclear whether anybody is still using
CPU emulation in QEMU, and there are no test images available to make
sure that the code is still working.
-``compat`` property of server class POWER CPUs (since 5.0)
-''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
-
-The ``compat`` property used to set backwards compatibility modes for
-the processor has been deprecated. The ``max-cpu-compat`` property of
-the ``pseries`` machine type should be used instead.
-
``lm32`` CPUs (since 5.2.0)
'''''''''''''''''''''''''''
diff --git a/target/ppc/translate_init.c.inc b/target/ppc/translate_init.c.inc
index 78cc8f043b92..e4082cfde746 100644
--- a/target/ppc/translate_init.c.inc
+++ b/target/ppc/translate_init.c.inc
@@ -10470,63 +10470,6 @@ static ObjectClass *ppc_cpu_class_by_name(const char *name)
return oc;
}
-static void ppc_cpu_parse_featurestr(const char *type, char *features,
- Error **errp)
-{
- Object *machine = qdev_get_machine();
- const PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(object_class_by_name(type));
-
- if (!features) {
- return;
- }
-
- if (object_property_find(machine, "max-cpu-compat")) {
- int i;
- char **inpieces;
- char *s = features;
- Error *local_err = NULL;
- char *compat_str = NULL;
-
- /*
- * Backwards compatibility hack:
- *
- * CPUs had a "compat=" property which didn't make sense for
- * anything except pseries. It was replaced by "max-cpu-compat"
- * machine option. This supports old command lines like
- * -cpu POWER8,compat=power7
- * By stripping the compat option and applying it to the machine
- * before passing it on to the cpu level parser.
- */
- inpieces = g_strsplit(features, ",", 0);
- *s = '\0';
- for (i = 0; inpieces[i]; i++) {
- if (g_str_has_prefix(inpieces[i], "compat=")) {
- warn_report_once("CPU 'compat' property is deprecated; "
- "use max-cpu-compat machine property instead");
- compat_str = inpieces[i];
- continue;
- }
- if ((i != 0) && (s != features)) {
- s = g_stpcpy(s, ",");
- }
- s = g_stpcpy(s, inpieces[i]);
- }
-
- if (compat_str) {
- char *v = compat_str + strlen("compat=");
- object_property_set_str(machine, "max-cpu-compat", v, &local_err);
- }
- g_strfreev(inpieces);
- if (local_err) {
- error_propagate(errp, local_err);
- return;
- }
- }
-
- /* do property processing with generic handler */
- pcc->parent_parse_features(type, features, errp);
-}
-
PowerPCCPUClass *ppc_cpu_get_family_class(PowerPCCPUClass *pcc)
{
ObjectClass *oc = OBJECT_CLASS(pcc);
@@ -10905,8 +10848,6 @@ static void ppc_cpu_class_init(ObjectClass *oc, void *data)
device_class_set_parent_reset(dc, ppc_cpu_reset, &pcc->parent_reset);
cc->class_by_name = ppc_cpu_class_by_name;
- pcc->parent_parse_features = cc->parse_features;
- cc->parse_features = ppc_cpu_parse_featurestr;
cc->has_work = ppc_cpu_has_work;
cc->do_interrupt = ppc_cpu_do_interrupt;
cc->cpu_exec_interrupt = ppc_cpu_exec_interrupt;
--
2.26.2
3 years, 11 months
[PATCH] polkit: Allow libvirt group access to libvirtd ro socket
by Jim Fehlig
As a normal user, 'virsh connect qemu:///system' and
'virsh connect --readonly qemu:///system' will prompt for root password.
If the user is added to the libvirt group, only
'virsh connect --readonly qemu:///system' will prompt for root password.
The libvirt polkit rules already allow libvirt group members access to
the rw socket. Add a rule allowing to access the ro socket.
Signed-off-by: Jim Fehlig <jfehlig(a)suse.com>
---
src/remote/libvirtd.rules | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/src/remote/libvirtd.rules b/src/remote/libvirtd.rules
index 01a15fac2e..d9be94fcc4 100644
--- a/src/remote/libvirtd.rules
+++ b/src/remote/libvirtd.rules
@@ -1,5 +1,12 @@
-// Allow any user in the 'libvirt' group to connect to system libvirtd
-// without entering a password.
+// Allow any user in the 'libvirt' group to connect to the system libvirtd
+// ro and rw sockets without entering a password.
+
+polkit.addRule(function(action, subject) {
+ if (action.id == "org.libvirt.unix.monitor" &&
+ subject.isInGroup("libvirt")) {
+ return polkit.Result.YES;
+ }
+});
polkit.addRule(function(action, subject) {
if (action.id == "org.libvirt.unix.manage" &&
--
2.29.2
3 years, 11 months
[PATCH 00/21] move checks from parse functions to post parse
by Daniel Henrique Barboza
Hi,
This started as a simple NVDIMM change, then I realized there
is a Gitlab work item for it [1], so I took the extra
mile and did a bit more. I'll copy/paste here the motivation
for this kind of change, provided by Cole in [1]:
-----
The code that handles domain/VM XML parsing (virDomainDefParseXML in
src/domain/domain_conf.c) has various validation checks sprinkled
within it. Many of these checks should be moved out of the parse step
and into virDomainDefPostParse, so they can be shared by various
places in the code that build a domain definition without XML, such
as converting from native vmware/virtualbox/xen formats.
-----
There are still checks to be moved after this work. If this is
accepted I'll update [1] with more details/tips about how to proceed
with the remaining checks.
Some g_auto* cleanups were done along the way.
[1] https://gitlab.com/libvirt/libvirt/-/issues/7
Daniel Henrique Barboza (21):
domain_conf.c: move NVDIMM 'labelsize' check to post parse
domain_conf.c: use g_autofree in 'dev' in virDomainDefParseBootXML()
domain_conf.c: modernize virDomainDefBootOrderPostParse()
domain_conf.c: move boot related timeouts check to post parse
domain_conf.c: do not leak 'video' in virDomainDefParseXML()
domain_conf.c: move primary video check to
virDomainDefPostParseVideo()
domain_conf.c: use g_autoptr() with virDomainVideoDefPtr
domain_conf.c: move QXL attributes check to
virDomainVideoDefPostParse()
virstorageencryption.h: add AUTOPTR_CLEANUP_FUNC for
virStorageEncryptionPtr
domain_conf: modernize virDomainDiskDefParseXML()
domain_conf.c: move vendor, product and tray checks to post parse
domain_conf.c: move smartcard address check to post parse
domain_conf.c: modernize virDomainSmartcardDefParseXML
domain_conf.c: remove 'error' label in virDomainDefTunablesParse()
domain_conf.c: move duplicate blkio path check to post parse
domain_conf.c: move virDomainPCIControllerOpts checks to post parse
domain_conf.c: move pci-root/pcie-root address check to post parse
domain_conf.c: modernize virDomainControllerDefParseXML()
domain_conf.c: modernize virDomainDefControllersParse()
domain_conf.c: use VIR_ERR_CONFIG_UNSUPPORTED in post parse
domain_conf.c: move idmapEntry checks to post parse
src/conf/domain_conf.c | 762 ++++++++++--------
src/conf/domain_conf.h | 4 +
src/util/virstorageencryption.h | 1 +
tests/qemuxml2argvdata/pci-root-address.err | 2 +-
.../pseries-default-phb-numa-node.err | 2 +-
.../video-multiple-primaries.err | 1 +
.../video-multiple-primaries.xml | 32 +
tests/qemuxml2argvtest.c | 5 +
8 files changed, 451 insertions(+), 358 deletions(-)
create mode 100644 tests/qemuxml2argvdata/video-multiple-primaries.err
create mode 100644 tests/qemuxml2argvdata/video-multiple-primaries.xml
--
2.26.2
3 years, 11 months
[PATCH 0/3] qemu: Couple of qemuDomainGetGuestInfo() related cleanups
by Michal Privoznik
While reviewing Marc-André's patches I've noticed couple of cleanup
possible.
Michal Prívozník (3):
qemuDomainGetGuestInfo: Exit early if getting info fails
virJSONValueObjectGetStringArray: Report error if @key is not an array
qemu: Use virJSONValueObjectGetStringArray() more
src/qemu/qemu_agent.c | 30 +++----------------
src/qemu/qemu_driver.c | 3 ++
src/qemu/qemu_monitor_json.c | 56 +++++-------------------------------
src/util/virjson.c | 6 +++-
4 files changed, 19 insertions(+), 76 deletions(-)
--
2.26.2
3 years, 11 months
[libvirt PATCH] docs: Update language bindings spotlight
by Andrea Bolognani
We should highlight the language bindings that are actively
maintained, keep up with the core library's development pace,
have good API coverage and are relevant to people looking to
integrate libvirt into their projects in $currentyear: based
on these criteria, it makes sense to highlight the Go binding
instead of the Java one.
Signed-off-by: Andrea Bolognani <abologna(a)redhat.com>
---
docs/index.html.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/index.html.in b/docs/index.html.in
index df182c27b6..f44e055174 100644
--- a/docs/index.html.in
+++ b/docs/index.html.in
@@ -18,7 +18,7 @@
</p>
<ul>
<li>is a toolkit to manage <a href="platforms.html">virtualization platforms</a></li>
- <li>is accessible from C, Python, Perl, Java and more</li>
+ <li>is accessible from C, Python, Perl, Go and more</li>
<li>is licensed under open source licenses</li>
<li>supports <a href="drvqemu.html">KVM</a>,
<a href="drvqemu.html">QEMU</a>, <a href="drvxen.html">Xen</a>,
--
2.26.2
3 years, 11 months
[PATCH] qemu: Recreate NUMA caps when creating connect capabilities
by Michal Privoznik
In v6.0.0-rc1~439 (and friends) we tried to cache NUMA
capabilities because we assumed they are immutable. And to some
extent they are (NUMA hotplug is not a thing, is it). However,
our capabilities contain also some runtime info that can change,
e.g. hugepages pool allocation sizes or total amount of memory
per node (host side memory hotplug might change the value).
When rebuilding virCaps (e.g. for 'virsh capabilities') we have
to dropped the cached info and rebuild it from scratch so that
the correct runtime info is reported.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1819058
Fixes: 1a1d848694f6c2f1d98a371124928375bc3bb4a3
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
After this, we are still caching CPU caps, but I'm not sure if that is a
problem. Perhaps if CPU was hotplugged/unplugged? I don't know.
src/qemu/qemu_conf.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
index d6615ca0dd..89a16349bf 100644
--- a/src/qemu/qemu_conf.c
+++ b/src/qemu/qemu_conf.c
@@ -1380,6 +1380,12 @@ virCapsPtr virQEMUDriverCreateCapabilities(virQEMUDriverPtr driver)
"DOI \"%s\"", model, doi);
}
+ /* Forcibly recreate NUMA caps. They are not static
+ * (e.g. size of hugepages pools can change). */
+ qemuDriverLock(driver);
+ g_clear_pointer(&driver->hostnuma, virCapabilitiesHostNUMAUnref);
+ qemuDriverUnlock(driver);
+
caps->host.numa = virQEMUDriverGetHostNUMACaps(driver);
caps->host.cpu = virQEMUDriverGetHostCPU(driver);
return g_steal_pointer(&caps);
--
2.26.2
3 years, 11 months
[PATCH v2] lxc: Cleanup after failed startup
by Michal Privoznik
If starting an container fails, the virLXCProcessStop() is
called. But since vm->def->id is not set until libvirt_lxc is
spawned (the domain's ID is PID of that process),
virLXCProcessStop() returns early as virDomainObjIsActive()
returns false. But doing so leaves behind resources reserved for
the containers during the startup process. Most notably, hostdevs
are not re-attached to the host, the domain's transient XML is
not removed, etc.
To resolve this, virLXCProcessCleanup() is called in this case.
However, it is modified to accept @flags which allows caller to
run only specific cleanups (depending how far in container
creation the failure occurred). There is plenty of cleanups which
don't need this guard because either they detect a NULL pointer
or try to release an unique resource.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
v2 of:
https://www.redhat.com/archives/libvir-list/2020-November/msg00317.html
diff to v1:
- Run some cleanups selectively
src/lxc/lxc_process.c | 52 ++++++++++++++++++++++++++++++++++---------
1 file changed, 41 insertions(+), 11 deletions(-)
diff --git a/src/lxc/lxc_process.c b/src/lxc/lxc_process.c
index c5a710fc3f..5763052e99 100644
--- a/src/lxc/lxc_process.c
+++ b/src/lxc/lxc_process.c
@@ -145,18 +145,27 @@ lxcProcessRemoveDomainStatus(virLXCDriverConfigPtr cfg,
}
+typedef enum {
+ VIR_LXC_PROCESS_CLEANUP_RELEASE_SECLABEL = (1 << 0),
+ VIR_LXC_PROCESS_CLEANUP_RESTORE_SECLABEL = (1 << 1),
+ VIR_LXC_PROCESS_CLEANUP_REMOVE_TRANSIENT = (1 << 2),
+} virLXCProcessCleanupFlags;
+
/**
* virLXCProcessCleanup:
* @driver: pointer to driver structure
* @vm: pointer to VM to clean up
* @reason: reason for switching the VM to shutoff state
+ * @flags: allows to run selective cleanups only
*
- * Cleanout resources associated with the now dead VM
- *
+ * Clean out resources associated with the now dead VM.
+ * If @flags is zero then whole cleanup process is done,
+ * otherwise only selected sections are run.
*/
static void virLXCProcessCleanup(virLXCDriverPtr driver,
virDomainObjPtr vm,
- virDomainShutoffReason reason)
+ virDomainShutoffReason reason,
+ unsigned int flags)
{
size_t i;
virLXCDomainObjPrivatePtr priv = vm->privateData;
@@ -164,8 +173,11 @@ static void virLXCProcessCleanup(virLXCDriverPtr driver,
virLXCDriverConfigPtr cfg = virLXCDriverGetConfig(driver);
virConnectPtr conn = NULL;
- VIR_DEBUG("Cleanup VM name=%s pid=%d reason=%d",
- vm->def->name, (int)vm->pid, (int)reason);
+ VIR_DEBUG("Cleanup VM name=%s pid=%d reason=%d flags=0x%x",
+ vm->def->name, (int)vm->pid, (int)reason, flags);
+
+ if (flags == 0)
+ flags = ~0;
/* now that we know it's stopped call the hook if present */
if (virHookPresent(VIR_HOOK_DRIVER_LXC)) {
@@ -177,9 +189,15 @@ static void virLXCProcessCleanup(virLXCDriverPtr driver,
NULL, xml, NULL);
}
- virSecurityManagerRestoreAllLabel(driver->securityManager,
- vm->def, false, false);
- virSecurityManagerReleaseLabel(driver->securityManager, vm->def);
+ if (flags & VIR_LXC_PROCESS_CLEANUP_RESTORE_SECLABEL) {
+ virSecurityManagerRestoreAllLabel(driver->securityManager,
+ vm->def, false, false);
+ }
+
+ if (flags & VIR_LXC_PROCESS_CLEANUP_RELEASE_SECLABEL) {
+ virSecurityManagerReleaseLabel(driver->securityManager, vm->def);
+ }
+
/* Clear out dynamically assigned labels */
if (vm->def->nseclabels &&
vm->def->seclabels[0]->type == VIR_DOMAIN_SECLABEL_DYNAMIC) {
@@ -258,7 +276,9 @@ static void virLXCProcessCleanup(virLXCDriverPtr driver,
NULL, xml, NULL);
}
- virDomainObjRemoveTransientDef(vm);
+ if (flags & VIR_LXC_PROCESS_CLEANUP_REMOVE_TRANSIENT)
+ virDomainObjRemoveTransientDef(vm);
+
virObjectUnref(cfg);
virObjectUnref(conn);
}
@@ -904,7 +924,7 @@ int virLXCProcessStop(virLXCDriverPtr driver,
}
cleanup:
- virLXCProcessCleanup(driver, vm, reason);
+ virLXCProcessCleanup(driver, vm, reason, 0);
return 0;
}
@@ -1198,6 +1218,7 @@ int virLXCProcessStart(virConnectPtr conn,
g_autoptr(virCgroup) selfcgroup = NULL;
int status;
g_autofree char *pidfile = NULL;
+ unsigned int stopFlags = 0;
if (virCgroupNewSelf(&selfcgroup) < 0)
return -1;
@@ -1265,6 +1286,7 @@ int virLXCProcessStart(virConnectPtr conn,
VIR_DEBUG("Setting current domain def as transient");
if (virDomainObjSetDefTransient(driver->xmlopt, vm, NULL) < 0)
goto cleanup;
+ stopFlags |= VIR_LXC_PROCESS_CLEANUP_REMOVE_TRANSIENT;
/* Run an early hook to set-up missing devices */
if (virHookPresent(VIR_HOOK_DRIVER_LXC)) {
@@ -1312,11 +1334,13 @@ int virLXCProcessStart(virConnectPtr conn,
goto cleanup;
}
virDomainAuditSecurityLabel(vm, true);
+ stopFlags |= VIR_LXC_PROCESS_CLEANUP_RELEASE_SECLABEL;
VIR_DEBUG("Setting domain security labels");
if (virSecurityManagerSetAllLabel(driver->securityManager,
vm->def, NULL, false, false) < 0)
goto cleanup;
+ stopFlags |= VIR_LXC_PROCESS_CLEANUP_RESTORE_SECLABEL;
VIR_DEBUG("Setting up consoles");
for (i = 0; i < vm->def->nconsoles; i++) {
@@ -1525,7 +1549,13 @@ int virLXCProcessStart(virConnectPtr conn,
}
if (rc != 0) {
virErrorPreserveLast(&err);
- virLXCProcessStop(driver, vm, VIR_DOMAIN_SHUTOFF_FAILED);
+ if (virDomainObjIsActive(vm)) {
+ virLXCProcessStop(driver, vm, VIR_DOMAIN_SHUTOFF_FAILED);
+ } else {
+ /* virLXCProcessStop() is NOP if the container is not active.
+ * If there was a failure whilst creating it, cleanup manually. */
+ virLXCProcessCleanup(driver, vm, VIR_DOMAIN_SHUTOFF_FAILED, stopFlags);
+ }
}
virCommandFree(cmd);
for (i = 0; i < nttyFDs; i++)
--
2.26.2
3 years, 11 months
[libvirt PATCH 0/9] qemu: report guest disks informations
by marcandre.lureau@redhat.com
From: Marc-André Lureau <marcandre.lureau(a)redhat.com>
Hi,
The following series extends virDomainGetGuestInfo to report disk informations
provided by the new QGA "guest-get-disks" command in QEMU 5.2.
Please review,
Fixes:
https://bugzilla.redhat.com/show_bug.cgi?id=1899527
Marc-André Lureau (9):
qemu_agent: rename qemuAgentDiskInfo->qemuAgentDiskAddress
qemu_agent: export qemuAgentDiskAddressFree & add g_auto
qemu_agent: factor out qemuAgentGetDiskAddress
util: json: add virJSONValueObjectGetStringArray convenience
qemu: use virJSONValueObjectGetStringArray
qemu_agent: add qemuAgentGetDisks
domain: add disk informations to virDomainGetGuestInfo
qemu_driver: report guest disk informations
virsh: add --disk informations to guestinfo command
include/libvirt/libvirt-domain.h | 1 +
src/libvirt-domain.c | 17 +++
src/libvirt_private.syms | 1 +
src/qemu/qemu_agent.c | 182 +++++++++++++++++++++++--------
src/qemu/qemu_agent.h | 25 ++++-
src/qemu/qemu_driver.c | 103 ++++++++++++++++-
src/qemu/qemu_monitor_json.c | 34 +-----
src/util/virjson.c | 30 +++++
src/util/virjson.h | 1 +
tests/qemuagenttest.c | 111 +++++++++++++++++++
tools/virsh-domain.c | 6 +
11 files changed, 430 insertions(+), 81 deletions(-)
--
2.29.0
3 years, 11 months
[PATCH v2 0/2] gitlab: Add issue templates
by Peter Krempa
Gitlab allows projects to define templates for filing issues [1].
Libvirt didn't have them yet. We can use them to encourage users to
file better bug reports and feature requests.
Differences to v1:
- dropped bug-qemu.md template
- vastly shortened comment blocks
- all comments are single line only to prevent users adding info inside
of them
- more fill-in fields instead of comment guidance
You can test-drive the proposed templates in my test repo:
https://gitlab.com/pipo.sk/test/-/issues/new
Peter Krempa (2):
gitlab: Add issue template for reporting a generic bug
gitlab: Add issue template for a feature request
.gitlab/issue_templates/bug.md | 26 ++++++++++++++++++++++++++
.gitlab/issue_templates/feature.md | 14 ++++++++++++++
2 files changed, 40 insertions(+)
create mode 100644 .gitlab/issue_templates/bug.md
create mode 100644 .gitlab/issue_templates/feature.md
--
2.28.0
3 years, 11 months