[pve-devel] [PATCH] Fix balloon0 device pci addr
Derumier Alexandre
aderumier at odiso.com
Fri Sep 30 13:10:27 CEST 2011
Signed-off-by: Derumier Alexandre <aderumier at odiso.com>
---
PVE/QemuServer.pm | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index 450b57d..27bccc7 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 },
--
1.7.2.5
More information about the pve-devel
mailing list