[pve-devel] r6203 - in qemu-server/pve2: . PVE

svn-commits at proxmox.com svn-commits at proxmox.com
Wed Jun 29 12:58:01 CEST 2011


Author: dietmar
Date: 2011-06-29 12:58:01 +0200 (Wed, 29 Jun 2011)
New Revision: 6203

Modified:
   qemu-server/pve2/ChangeLog
   qemu-server/pve2/PVE/QemuServer.pm
Log:
implement -cpu option


Modified: qemu-server/pve2/ChangeLog
===================================================================
--- qemu-server/pve2/ChangeLog	2011-06-29 09:12:04 UTC (rev 6202)
+++ qemu-server/pve2/ChangeLog	2011-06-29 10:58:01 UTC (rev 6203)
@@ -1,3 +1,7 @@
+2011-06-29  Proxmox Support Team  <support at proxmox.com>
+
+	* PVE/QemuServer.pm (config_to_command): implement -cpu option
+
 2011-06-15  Proxmox Support Team  <support at proxmox.com>
 
 	* PVE/QemuServer.pm (vmstatus): include IO stat

Modified: qemu-server/pve2/PVE/QemuServer.pm
===================================================================
--- qemu-server/pve2/PVE/QemuServer.pm	2011-06-29 09:12:04 UTC (rev 6202)
+++ qemu-server/pve2/PVE/QemuServer.pm	2011-06-29 10:58:01 UTC (rev 6203)
@@ -373,6 +373,13 @@
 	typetext => 'volume',
 	description => "This is an alias for option -ide2",
     },
+    cpu => {
+	optional => 1,
+	description => "Emulated CPU type",
+	type => 'string',
+	enum => [ qw(486 athlon pentium pentium2 pentium3 coreduo core2duo kvm32 kvm64 qemu32 qemu64 phenom host) ],
+	default => 'qemu64',
+    },
 };
 
 # what about other qemu settings ?
@@ -1873,6 +1880,8 @@
 
     push @$cmd, '-smp', "sockets=$sockets,cores=$cores";
 
+    push @$cmd, '-cpu', $conf->{cpu} if $conf->{cpu};
+
     $boot_opt = "menu=on";
     if ($conf->{boot}) {
 	$boot_opt .= ",order=$conf->{boot}";




More information about the pve-devel mailing list