Received: from eggs.gnu.org ([2001:4830:134:3::10]:43802) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bsU4N-00066V-1u for qemu-devel@nongnu.org; Fri, 07 Oct 2016 08:16:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bsU4I-0001m1-VT for qemu-devel@nongnu.org; Fri, 07 Oct 2016 08:16:06 -0400 From: Date: Fri, 7 Oct 2016 11:42:11 +0200 Message-ID: <1475833331-26882-1-git-send-email-marcin.krzeminski@nokia.com> MIME-Version: 1.0 Content-Type: text/plain Subject: [Qemu-devel] [PATCH] nvic: allow to set pending status for not active interrupts List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: qemu-arm@nongnu.org, peter.maydell@linaro.org, rfsw-patches@mlist.nokia.com From: Marcin Krzeminski According to ARM DUI 0552A 4.2.10. NVIC set pending status also for disabled interrupts. This patch adds possibility to emulate this in Qemu. Signed-off-by: Marcin Krzeminski --- hw/intc/arm_gic.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/intc/arm_gic.c b/hw/intc/arm_gic.c index b30cc91..85be6e4 100644 --- a/hw/intc/arm_gic.c +++ b/hw/intc/arm_gic.c @@ -147,7 +147,8 @@ static void gic_set_irq_11mpcore(GICState *s, int irq, int level, { if (level) { GIC_SET_LEVEL(irq, cm); - if (GIC_TEST_EDGE_TRIGGER(irq) || GIC_TEST_ENABLED(irq, cm)) { + if (GIC_TEST_EDGE_TRIGGER(irq) || GIC_TEST_ENABLED(irq, cm) + || (!GIC_TEST_ACTIVE(irq, cm) && s->revision == REV_NVIC)) { DPRINTF("Set %d pending mask %x\n", irq, target); GIC_SET_PENDING(irq, target); } -- 2.7.4