[PATCH] esx: Avoid corner case where esxUtil_ParseDatastorePath could be called with NULL 'datastorePath'
by Peter Krempa
From: Peter Krempa <pkrempa(a)redhat.com>
The generated code which parses the data from XML in
esxVI_LookupDatastoreContentByDatastoreName can fill the 'folderPath'
property with NULL if it were missing from the input XML. While this is
not likely when talking to esx it is a possible outcome. Skipp NULL
results.
All other code paths already ensure that the function is not called with
NULL.
Closes: https://gitlab.com/libvirt/libvirt/-/issues/776
Signed-off-by: Peter Krempa <pkrempa(a)redhat.com>
---
src/esx/esx_storage_backend_vmfs.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/esx/esx_storage_backend_vmfs.c b/src/esx/esx_storage_backend_vmfs.c
index 145aff0c9c..8e13201fe2 100644
--- a/src/esx/esx_storage_backend_vmfs.c
+++ b/src/esx/esx_storage_backend_vmfs.c
@@ -616,6 +616,9 @@ esxStoragePoolListVolumes(virStoragePoolPtr pool, char **const names,
searchResults = searchResults->_next) {
g_autofree char *directoryAndFileName = NULL;
+ if (!searchResults->folderPath)
+ continue;
+
if (esxUtil_ParseDatastorePath(searchResults->folderPath, NULL, NULL,
&directoryAndFileName) < 0) {
goto cleanup;
@@ -759,6 +762,9 @@ esxStorageVolLookupByKey(virConnectPtr conn, const char *key)
searchResults = searchResults->_next) {
g_autofree char *directoryAndFileName = NULL;
+ if (searchResults->folderPath)
+ continue;
+
if (esxUtil_ParseDatastorePath(searchResults->folderPath, NULL,
NULL, &directoryAndFileName) < 0) {
goto cleanup;
--
2.49.0
1 day, 23 hours
Release of libvirt-11.4.0
by Jiri Denemark
The 11.4.0 release of both libvirt and libvirt-python is tagged and
signed tarballs are available at
https://download.libvirt.org/
https://download.libvirt.org/python/
Thanks everybody who helped with this release by sending patches,
reviewing, testing, or providing feedback. Your work is greatly
appreciated.
* New features
* qemu: ppc64 POWER11 processor support
Support for the recently released IBM POWER11 processor was added.
* Packaging changes
* All helper programs are now detected from ``$PATH`` during runtime
All of the code was now converted to dynamically look up helper programs
in ``$PATH`` rather than doing the lookup at build time and then compiling
in the result.
Programs ``mount``, ``umount``, ``mkfs``, ``modprobe``, ``rmmod``,
``numad``, ``dmidecode``, ``ip``, ``tc``, ``mdevctl``, ``mm-ctl``,
``iscsiadm``, ``ovs-vsctl``, ``pkttyagent``, ``bhyveload``, ``bhyvectl``,
``bhyve``, ``ifconfig``, ``vzlist``, ``vzctl``, ``vzmigrate``, and the
tools from the lvm suite (``vgchange``, ``lvcreate``, etc..) are now not
needed during build and will still work properly if placed in ``$PATH``.
This also ensures that libvirt works correctly on distros that are
transitioning ``/sbin`` into ``/bin`` and upgraded installations have
a different layout from fresh installations.
* Improvements
* virsh: Add option ``--no-pkttyagent``
That option suppresses registration of pkttyagent with polkitd.
* bhyve: support NVRAM configuration for UEFI firmwares
The bhyve driver now supports specifying NVRAM store file, such as::
<os firmware='efi'>
<nvram/>
</os>
* qemu: Improve accuracy of FDC/floppy device support statement in capabilities XML
The data is now based on the presence of the controller in qemu rather than
just a denylist of machine types where floppies not work.
* Bug fixes
* qemu: Fix failure when reverting to internal snapshots
A regression in ``libvirt-11.2`` and ``libvirt-11.3`` prevents reverting to
an internal snapshot. Attempts to revert would produce the following error::
error: operation failed: load of internal snapshot 'foo1' job failed: Device 'libvirt-1-format' is writable but does not support snapshots
The only workaround is to avoid the broken versions.
* qemu: Fix virtqemud crash when resuming failed post-copy migration
A regression introduced in ``libvirt-11.2.0`` caused virtqemud on the
destination host to crash when trying to resume failed post-copy
migration.
* qemu: Treat the ``queues`` configuration of ``virtio-net`` as guest ABI
The queue count itself isn't a device frontend property but libvirt uses
it to calculate ``vectors`` option of the device which is a guest OS visible
property, thus ``queues`` must not change during migration. The ABI stability
check now handles this properly.
Enjoy.
Jirka
2 days
[PATCH 0/1] cpu_map: fix vmx-* features wrong bitmaps
by Hector Cao
Hello,
I'm unable to make virsh capabilities to detect the right CPU model
on an Intel Granite Rapids platform. I would expect the get the
CPU model defined in one of the src/cpu_map/x86_GraniteRapids*.xml
files.
The cause of the wrong detection is the fact that some vmx-* are
not correctly detected and considered missing on this platform.
When I take a look at the src/cpu_map/x86_features.xml file, I
think that some of the vmx-* are wrongly defined.
Taking as an example the vmx-apicv-xapic feature, it is defined as
the first bit in the EAX register when we read the MSR 0x0000048b .
But in Intel specification, this feature is represented as the first
bit in the EDX register (32 higher bits).
You can find in this submission the patch that fixes this issue,
and this for all the affected MSRs.
I tested this fix on my Granite Rapids platform and the CPU model
is now correctly detected.
Hector Cao (1):
cpu_map: fix vmx-* features wrong bitmaps
src/cpu_map/x86_features.xml | 136 +++++++++++++++++------------------
1 file changed, 68 insertions(+), 68 deletions(-)
--
2.45.2
2 days, 11 hours
[PATCH v2 0/4] bhyve: implement domain{Block,Interface,Memory}Stats
by Roman Bogorodskiy
Changes since v1:
- Added "bhyve: implement domainInterfaceStats" patch
PS It was temping to factor out obtaining struct kinfo_proc using
sysctlnametomib() + sysctl(), but I have to make it visible to use
outside of virprocess, e.g. in bhyve_driver.c, so it doesn't look like
it's worth the effort for now. Probably it'll make sense to implement a
FreeBSD version of virProcessGetStat() once there are more users of this
code.
Roman Bogorodskiy (4):
bhyve: implement domainInterfaceStats
virprocess: implement virProcessGetStatInfo() for FreeBSD
bhyve: implement domainMemoryStats
bhyve: implement domainBlockStats
src/bhyve/bhyve_driver.c | 140 +++++++++++++++++++++++++++++++++++++++
src/util/virprocess.c | 104 +++++++++++++++++++++--------
2 files changed, 218 insertions(+), 26 deletions(-)
--
2.49.0
3 days, 3 hours