From patchwork Fri Jan 15 22:37:30 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Artyom Tarasenko X-Patchwork-Id: 42999 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id C5FD41007D6 for ; Sat, 16 Jan 2010 09:45:50 +1100 (EST) Received: from localhost ([127.0.0.1]:38482 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NVup0-0006Qg-02 for incoming@patchwork.ozlabs.org; Fri, 15 Jan 2010 17:39:14 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NVunT-0006Ie-L9 for qemu-devel@nongnu.org; Fri, 15 Jan 2010 17:37:39 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NVunP-0006Gv-0i for qemu-devel@nongnu.org; Fri, 15 Jan 2010 17:37:39 -0500 Received: from [199.232.76.173] (port=56866 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NVunO-0006Gp-T6 for qemu-devel@nongnu.org; Fri, 15 Jan 2010 17:37:34 -0500 Received: from mail-fx0-f222.google.com ([209.85.220.222]:47533) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NVunO-0006wB-G3 for qemu-devel@nongnu.org; Fri, 15 Jan 2010 17:37:34 -0500 Received: by fxm22 with SMTP id 22so775568fxm.2 for ; Fri, 15 Jan 2010 14:37:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer; bh=3Bcd+KFMsp0ikdAa4RpTYiU+zjm1iWpZIqqoGKvAg7A=; b=d5M1ASnRQBoJh4TgW7L5YM+63No5aoex18hN/YP7b1IhJodnhE+hDqAcK0RxOAvPPf Ov7g8eWAdsEtFPmRIXOZs60SWhHxgpRLvsGC0aBHnwl3EKAAreZBivlKMZniy9GS234T j77W4s9U0+1DCvQXJrl1QQv0xrTWx3LWuR4AQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=FGI8OcklH7pCLaSMx1hBL1xeA9wMgjgzcOfmKtvJ9urD/4qzDe9SGypbH2Y6w0zMod bGOHgrNezLLomvz+/slXx8zTJPenrLX66blq9R2KHujRkAO4UMw8RPWpSd4ZMgmi2yWu c4dSBroiiaExPOD788TB7KFDvlTmkhknV8+xQ= Received: by 10.223.13.202 with SMTP id d10mr2255072faa.40.1263595053116; Fri, 15 Jan 2010 14:37:33 -0800 (PST) Received: from localhost (e181210186.adsl.alicedsl.de [85.181.210.186]) by mx.google.com with ESMTPS id p9sm1142830fkb.44.2010.01.15.14.37.31 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 15 Jan 2010 14:37:32 -0800 (PST) From: Artyom Tarasenko To: qemu-devel@nongnu.org Date: Fri, 15 Jan 2010 23:37:30 +0100 Message-Id: <1263595050-17791-1-git-send-email-atar4qemu@google.com> X-Mailer: git-send-email 1.6.2.5 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Cc: Blue Swirl , Artyom Tarasenko Subject: [Qemu-devel] sparc32 do not clear interrupts when masking X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Don't clear interrupts on disabling, because * Sun4M_SystemArchitecture_edited2.pdf doesn't describe that masking or un-masking IRQ shall clear pending ones. * Field tests also show that SPARCstation-20 doesn't clear them. * The patch makes Solaris 2.5.1/2.6 boot ~1500 times faster (~20 seconds instead of ~8 hours) Signed-off-by: Artyom Tarasenko diff --git a/hw/slavio_intctl.c b/hw/slavio_intctl.c index 9aff892..b76d3ac 100644 --- a/hw/slavio_intctl.c +++ b/hw/slavio_intctl.c @@ -185,11 +185,10 @@ static void slavio_intctlm_mem_writel(void *opaque, target_phys_addr_t addr, s->intregm_disabled); slavio_check_interrupts(s, 1); break; - case 3: // set (disable, clear pending) + case 3: // set (disable; doesn't affect pending) // Force clear unused bits val &= MASTER_IRQ_MASK; s->intregm_disabled |= val; - s->intregm_pending &= ~val; slavio_check_interrupts(s, 1); DPRINTF("Disabled master irq mask %x, curmask %x\n", val, s->intregm_disabled);