From b12110c5db38dcce61747f31192bb2f5681e27cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Revol?= Date: Sun, 19 Jul 2009 20:14:38 +0000 Subject: [PATCH] Use a define for max cpu count. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31644 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- 3rdparty/mmu_man/onlinedemo/haiku.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/3rdparty/mmu_man/onlinedemo/haiku.php b/3rdparty/mmu_man/onlinedemo/haiku.php index 4dee13f064..7e539b4471 100755 --- a/3rdparty/mmu_man/onlinedemo/haiku.php +++ b/3rdparty/mmu_man/onlinedemo/haiku.php @@ -77,6 +77,10 @@ define("QEMU_ARGS", "" define("QEMU_IMAGE_PATH", "/home/revol/haiku.image"); // BAD: let's one download the image //define("QEMU_IMAGE_PATH", dirname($_SERVER['SCRIPT_FILENAME']) . "/haiku.image"); + +// max number of cpus for the VM, not more than 8 +define("QEMU_MAX_CPUS", 1); + // qemu 0.8.2 needs "", qemu 0.9.1 needs ":" define("QEMU_VNC_PREFIX", ":"); @@ -291,9 +295,8 @@ function probe_options_form() $cpucount = 1; if (isset($_GET['cpucount'])) $cpucount = (int)$_GET['cpucount']; - $cpucount = max(min($cpucount, 8), 1); + $cpucount = max(min($cpucount, QEMU_MAX_CPUS), 1); //dbg("cpucount $cpucount"); - $cpucount = 1; // force for now } @@ -344,19 +347,18 @@ function output_options_form() echo "\n\n"; - $maxcpus = 8; echo "\n"; echo "\n"; echo "Select cpu count:"; echo "\n\n"; echo "