From patchwork Thu May 30 16:22:30 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Chouteau X-Patchwork-Id: 247641 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id EDB592C00AB for ; Fri, 31 May 2013 02:23:02 +1000 (EST) Received: from localhost ([::1]:45110 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ui5cz-0006yP-56 for incoming@patchwork.ozlabs.org; Thu, 30 May 2013 12:23:01 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52894) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ui5cf-0006sb-U4 for qemu-devel@nongnu.org; Thu, 30 May 2013 12:22:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ui5ca-0008Gm-Ts for qemu-devel@nongnu.org; Thu, 30 May 2013 12:22:41 -0400 Received: from mel.act-europe.fr ([194.98.77.210]:52762 helo=smtp.eu.adacore.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ui5ca-0008Ea-MY for qemu-devel@nongnu.org; Thu, 30 May 2013 12:22:36 -0400 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id 9F3532648CFF; Thu, 30 May 2013 18:21:00 +0200 (CEST) Received: from smtp.eu.adacore.com ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id r2QhyXGFgrzX; Thu, 30 May 2013 18:21:00 +0200 (CEST) Received: from PomPomGalli.act-europe.fr (pompomgalli.act-europe.fr [10.10.1.88]) (using TLSv1.1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.eu.adacore.com (Postfix) with ESMTPSA id ED6D52648A71; Thu, 30 May 2013 18:20:59 +0200 (CEST) From: Fabien Chouteau To: qemu-devel@nongnu.org Date: Thu, 30 May 2013 18:22:30 +0200 Message-Id: <1369930950-18564-1-git-send-email-chouteau@adacore.com> X-Mailer: git-send-email 1.7.9.5 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 194.98.77.210 Cc: blauwirbel@gmail.com, peter.maydell@linaro.org, pbonzini@redhat.com, afaerber@suse.de, rth@twiddle.net Subject: [Qemu-devel] [PATCH] ARM: Fix disable interrupt for M profile X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org I'm not sure this was expected or not, but it looks like the "||" should be a "&&". Otherwise it's not possible to disable interrupt. Signed-off-by: Fabien Chouteau --- cpu-exec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cpu-exec.c b/cpu-exec.c index 31c089d..079b6f0 100644 --- a/cpu-exec.c +++ b/cpu-exec.c @@ -462,8 +462,8 @@ int cpu_exec(CPUArchState *env) We avoid this by disabling interrupts when pc contains a magic address. */ if (interrupt_request & CPU_INTERRUPT_HARD - && ((IS_M(env) && env->regs[15] < 0xfffffff0) - || !(env->uncached_cpsr & CPSR_I))) { + && (IS_M(env) && env->regs[15] < 0xfffffff0) + && !(env->uncached_cpsr & CPSR_I)) { env->exception_index = EXCP_IRQ; cc->do_interrupt(cpu); next_tb = 0;