From mboxrd@z Thu Jan 1 00:00:00 1970 From: Glauber Costa Subject: [PATCH 09/13] [PATCH] move disabling code to kqemu.c instead of vl.c Date: Thu, 15 May 2008 11:09:29 -0300 Message-ID: <12108606081482-git-send-email-gcosta@redhat.com> References: <12108605731805-git-send-email-gcosta@redhat.com> <12108605813076-git-send-email-gcosta@redhat.com> <12108605843020-git-send-email-gcosta@redhat.com> <12108605883967-git-send-email-gcosta@redhat.com> <12108605912878-git-send-email-gcosta@redhat.com> <121086059420-git-send-email-gcosta@redhat.com> <12108605981240-git-send-email-gcosta@redhat.com> <12108606012733-git-send-email-gcosta@redhat.com> <12108606053604-git-send-email-gcosta@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel@lists.sourceforge.net, avi@qumranet.com To: qemu-devel@nongnu.org Return-path: In-Reply-To: <12108606053604-git-send-email-gcosta@redhat.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces@lists.sourceforge.net Errors-To: kvm-devel-bounces@lists.sourceforge.net List-Id: kvm.vger.kernel.org this is for the case in which we run more than one cpu --- kqemu.c | 3 ++- vl.c | 4 ---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/kqemu.c b/kqemu.c index 6d46dfb..94366ec 100644 --- a/kqemu.c +++ b/kqemu.c @@ -164,6 +164,7 @@ static void kqemu_update_cpuid(CPUState *env) } QEMUAccel kqemu_accel; +extern int smp_cpus; int kqemu_start(void) { @@ -173,7 +174,7 @@ int kqemu_start(void) DWORD temp; #endif - if (!kqemu_allowed) + if (!kqemu_allowed || smp_cpus > 1) return -1; #ifdef _WIN32 diff --git a/vl.c b/vl.c index 26c1677..8104e33 100644 --- a/vl.c +++ b/vl.c @@ -8357,10 +8357,6 @@ int main(int argc, char **argv) exit(1); } -#ifdef USE_KQEMU - if (smp_cpus > 1) - kqemu_allowed = 0; -#endif linux_boot = (kernel_filename != NULL); net_boot = (boot_devices_bitmap >> ('n' - 'a')) & 0xF; -- 1.5.5 ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/