[pve-devel] [PATCH] vga=none if x-vga passthrough is enabled
Alexandre Derumier
aderumier at odiso.com
Wed Aug 6 07:27:29 CEST 2014
we need to disable virtual vga card if we passthrough a physical gpu
Signed-off-by: Alexandre Derumier <aderumier at odiso.com>
---
PVE/QemuServer.pm | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index 86d3837..7785b2e 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -2485,8 +2485,10 @@ sub config_to_command {
my $rombar = $d->{rombar} && $d->{rombar} eq 'off' ? ",rombar=0" : "";
my $driver = $d->{driver} && $d->{driver} eq 'vfio' ? "vfio-pci" : "pci-assign";
my $xvga = $d->{'x-vga'} && $d->{'x-vga'} eq 'on' ? ",x-vga=on" : "";
- push @$cpuFlags, 'kvm=off' if $xvga && $xvga ne '';
-
+ if ($xvga && $xvga ne '') {
+ push @$cpuFlags, 'kvm=off';
+ $vga = 'none';
+ }
$driver = "vfio-pci" if $xvga ne '';
my $pcidevices = $d->{pciid};
my $multifunction = 1 if @$pcidevices > 1;
--
1.7.10.4
More information about the pve-devel
mailing list