From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44054) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XJMQk-0000nj-Sx for qemu-devel@nongnu.org; Mon, 18 Aug 2014 08:53:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XJMQf-0005Xw-76 for qemu-devel@nongnu.org; Mon, 18 Aug 2014 08:52:58 -0400 Received: from os.inf.tu-dresden.de ([2002:8d4c:3001:48::99]:44840) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XJMQe-0005Xn-VJ for qemu-devel@nongnu.org; Mon, 18 Aug 2014 08:52:53 -0400 Date: Mon, 18 Aug 2014 14:52:47 +0200 From: Adam Lackorzynski Message-ID: <20140818125247.GB4673@os.inf.tu-dresden.de> References: <1408218501-22326-1-git-send-email-adam@os.inf.tu-dresden.de> <1408218501-22326-4-git-send-email-adam@os.inf.tu-dresden.de> <20140818124815.GD19635@cbox> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <20140818124815.GD19635@cbox> Subject: Re: [Qemu-devel] [PATCH 3/3] arm_gic: Do not force PPIs to edge-triggered mode List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Christoffer Dall Cc: qemu-devel@nongnu.org On Mon Aug 18, 2014 at 14:48:15 +0200, Christoffer Dall wrote: > On Sat, Aug 16, 2014 at 09:48:21PM +0200, Adam Lackorzynski wrote: > > Only SGIs must be WI, done by forcing them to their default > > (edge-triggered). > > > > 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 e546647..55019c9 100644 > > --- a/hw/intc/arm_gic.c > > +++ b/hw/intc/arm_gic.c > > @@ -558,7 +558,7 @@ static void gic_dist_writeb(void *opaque, hwaddr offset, > > irq = (offset - 0xc00) * 4 + GIC_BASE_IRQ; > > if (irq >= s->num_irq) > > goto bad_reg; > > - if (irq < GIC_INTERNAL) > > + if (irq < GIC_NR_SGIS) > > value |= 0xaa; > > for (i = 0; i < 4; i++) { > > if (s->revision == REV_11MPCORE || s->revision == REV_NVIC) { > > -- > > 2.1.0.rc1 > > > > where do we ensure that the SGIs are actually configured as > edge-triggered when creating the gic? It's setup in arm_gic_common_reset() in arm_gic_common.c. (Looks like I should add another change to use GIC_NR_SGIS there too.) Adam -- Adam adam@os.inf.tu-dresden.de Lackorzynski http://os.inf.tu-dresden.de/~adam/