* [PATCH qemu-server] hotplug pending: use machine type from running instance to avoid mismatch
@ 2026-08-03 15:22 Fiona Ebner
0 siblings, 0 replies; only message in thread
From: Fiona Ebner @ 2026-08-03 15:22 UTC (permalink / raw)
To: pve-devel
The machine version from the configuration might be using the 'latest'
version, in which case the currently running machine version might be
different from the version of the installed QEMU binary. This is an
issue, because sub-calls of vmconfig_hotplug_pending() like
print_drivedevice_full() use the binary version as a fallback when
there is an unresolved 'latest' version. Hotplug needs to respect the
current running machine version for migration compatibility.
This also allows simplifying the call for the USB hotplug check,
because the 'latest' version is now already resolved to the explicit
version.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
src/PVE/QemuServer.pm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/PVE/QemuServer.pm b/src/PVE/QemuServer.pm
index 9aec7f9c..d8dd9ea1 100644
--- a/src/PVE/QemuServer.pm
+++ b/src/PVE/QemuServer.pm
@@ -4602,7 +4602,7 @@ sub vmconfig_hotplug_pending {
my $defaults = load_defaults();
my $arch = PVE::QemuServer::Helpers::get_vm_arch($conf);
- my $machine_type = PVE::QemuServer::Machine::get_vm_machine($conf);
+ my $machine_type = PVE::QemuServer::Machine::get_current_qemu_machine($vmid);
# commit values which do not have any impact on running VM first
# Note: those option cannot raise errors, we we do not care about
@@ -4701,7 +4701,7 @@ sub vmconfig_hotplug_pending {
my $is_usb_hotplug_supported = sub {
return $usb_hotplug if defined($usb_hotplug);
my $ostype = $conf->{ostype};
- my $version = extract_version($machine_type, get_running_qemu_version($vmid));
+ my $version = PVE::QemuServer::Machine::extract_version($machine_type);
$usb_hotplug =
$hotplug_features->{usb}
&& min_version($version, 7, 1)
--
2.47.3
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-08-03 15:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-03 15:22 [PATCH qemu-server] hotplug pending: use machine type from running instance to avoid mismatch Fiona Ebner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox