From 13b5a75337c82be276aa9a27b6e0321ff8633049 Mon Sep 17 00:00:00 2001 From: Derumier Alexandre Date: Fri, 30 Sep 2011 13:10:27 +0200 Subject: [PATCH] Fix balloon0 device pci addr Signed-off-by: Derumier Alexandre --- PVE/QemuServer.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index 450b57df..27bccc72 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -2098,8 +2098,8 @@ sub config_to_command { #my $soundhw = $conf->{soundhw} || $defaults->{soundhw}; #push @$cmd, '-soundhw', 'es1370'; #push @$cmd, '-soundhw', $soundhw if $soundhw; - - push @$cmd, '-device', 'virtio-balloon-pci,id=balloon0' if $conf->{balloon}; + my $pciaddr = print_pci_addr("balloon0"); + push @$cmd, '-device', "virtio-balloon-pci,id=balloon0$pciaddr" if $conf->{balloon}; if ($conf->{watchdog}) { my $wdopts = parse_watchdog($conf->{watchdog}); @@ -2799,6 +2799,7 @@ sub print_pci_addr { my $res = ''; my $devices = { + balloon0 => { bus => 0, addr => 3 }, virtio0 => { bus => 0, addr => 10 }, virtio1 => { bus => 0, addr => 11 }, virtio2 => { bus => 0, addr => 12 },