From patchwork Mon Aug 18 13:07:57 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Lackorzynski X-Patchwork-Id: 381003 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id EBF6414007D for ; Mon, 18 Aug 2014 23:08:57 +1000 (EST) Received: from localhost ([::1]:43800 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XJMgC-000688-0q for incoming@patchwork.ozlabs.org; Mon, 18 Aug 2014 09:08:56 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47878) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XJMfX-00054o-K2 for qemu-devel@nongnu.org; Mon, 18 Aug 2014 09:08:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XJMfL-0001pr-3a for qemu-devel@nongnu.org; Mon, 18 Aug 2014 09:08:15 -0400 Received: from os.inf.tu-dresden.de ([2002:8d4c:3001:48::99]:45083) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XJMfK-0001pB-RR for qemu-devel@nongnu.org; Mon, 18 Aug 2014 09:08:03 -0400 Received: from erwin.inf.tu-dresden.de ([141.76.48.80] helo=x) by os.inf.tu-dresden.de with esmtp (Exim 4.84) id 1XJMfJ-0001Cz-Tl; Mon, 18 Aug 2014 15:08:01 +0200 From: Adam Lackorzynski To: qemu-devel@nongnu.org Date: Mon, 18 Aug 2014 15:07:57 +0200 Message-Id: <1408367280-5093-2-git-send-email-adam@os.inf.tu-dresden.de> X-Mailer: git-send-email 2.1.0.rc1 In-Reply-To: <1408367280-5093-1-git-send-email-adam@os.inf.tu-dresden.de> References: <1408367280-5093-1-git-send-email-adam@os.inf.tu-dresden.de> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2002:8d4c:3001:48::99 Cc: christoffer.dall@linaro.org Subject: [Qemu-devel] [PATCH 1/4] arm_gic: Fix read of GICD_ICFGR 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 The GICD_ICFGR register covers 4 interrupts per byte. Acked-by: Christoffer Dall Signed-off-by: Adam Lackorzynski --- hw/intc/arm_gic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/intc/arm_gic.c b/hw/intc/arm_gic.c index 1532ef9..d2b1aaf 100644 --- a/hw/intc/arm_gic.c +++ b/hw/intc/arm_gic.c @@ -372,7 +372,7 @@ static uint32_t gic_dist_readb(void *opaque, hwaddr offset) } } else if (offset < 0xf00) { /* Interrupt Configuration. */ - irq = (offset - 0xc00) * 2 + GIC_BASE_IRQ; + irq = (offset - 0xc00) * 4 + GIC_BASE_IRQ; if (irq >= s->num_irq) goto bad_reg; res = 0;