[pve-devel] [PATCH 2/2] fix watchdog pci addr
Derumier Alexandre
aderumier at odiso.com
Mon Oct 3 14:53:10 CEST 2011
Signed-off-by: Derumier Alexandre <aderumier at odiso.com>
---
PVE/QemuServer.pm | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index e7a053b..30ccb41 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -2104,7 +2104,9 @@ sub config_to_command {
if ($conf->{watchdog}) {
my $wdopts = parse_watchdog($conf->{watchdog});
- push @$cmd, '-watchdog', $wdopts->{model} || 'i6300esb';
+ $pciaddr = print_pci_addr("watchdog");
+ my $watchdog = $wdopts->{model} || 'i6300esb';
+ push @$cmd, '-device', "$watchdog$pciaddr";
push @$cmd, '-watchdog-action', $wdopts->{action} if $wdopts->{action};
}
@@ -2801,6 +2803,7 @@ sub print_pci_addr {
my $res = '';
my $devices = {
balloon0 => { bus => 0, addr => 3 },
+ watchdog => { bus => 0, addr => 4 },
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