code cleanup: drop unused parameter from get_vm_machine()

The parameter was added by ac0077cc ("Use 'QEMU version' ->
'+pve-version' mapping for machine types") but it doesn't seem like
there ever was a caller. In particular, none of the current callers
pass in a value and it's not clear when one would require passing a
different version than the KVM binary version.

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
Reviewed-by: Daniel Kral <d.kral@proxmox.com>
Tested-by: Daniel Kral <d.kral@proxmox.com>
This commit is contained in:
Fiona Ebner 2024-07-23 17:25:39 +02:00 committed by Thomas Lamprecht
parent 14374ab1bd
commit e1bdb0ad44

View File

@ -3313,13 +3313,13 @@ sub windows_get_pinned_machine_version {
}
sub get_vm_machine {
my ($conf, $forcemachine, $arch, $add_pve_version, $kvmversion) = @_;
my ($conf, $forcemachine, $arch, $add_pve_version) = @_;
my $machine_conf = PVE::QemuServer::Machine::parse_machine($conf->{machine});
my $machine = $forcemachine || $machine_conf->{type};
if (!$machine || $machine =~ m/^(?:pc|q35|virt)$/) {
$kvmversion //= kvm_user_version();
my $kvmversion //= kvm_user_version();
# we must pin Windows VMs without a specific version to 5.1, as 5.2 fixed a bug in ACPI
# layout which confuses windows quite a bit and may result in various regressions..
# see: https://lists.gnu.org/archive/html/qemu-devel/2021-02/msg08484.html