]> git.proxmox.com Git - qemu-server.git/commitdiff
use machine version in vga default type selection
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 12 Jul 2017 09:16:17 +0000 (11:16 +0200)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Fri, 14 Jul 2017 11:20:24 +0000 (13:20 +0200)
If we get an VM machine older than 2.9 we use the old selection
expression for the VGA type. This allows to live migrate VMs to PVE
5.0.
Also once kvm gets updated to 2.9 in PVE 4.4 newly started VMs will
use "std" as default VGA instead of cirrus.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
PVE/QemuServer.pm

index d76af660a166ca56cd27ad274de08a41a40903e1..c09168534661b898450d7785f7db5066745a6ab5 100644 (file)
@@ -2880,7 +2880,11 @@ sub config_to_command {
     $vga = 'qxl' if $qxlnum;
 
     if (!$vga) {
-       $vga = $winversion >= 6 ? 'std' : 'cirrus';
+       if (qemu_machine_feature_enabled($machine_type, $kvmver, 2, 9)) {
+           $vga = (!$winversion || $winversion >= 6) ? 'std' : 'cirrus';
+       } else {
+           $vga = ($winversion >= 6) ? 'std' : 'cirrus';
+       }
     }
 
     # enable absolute mouse coordinates (needed by vnc)