From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751444AbaC2JTJ (ORCPT ); Sat, 29 Mar 2014 05:19:09 -0400 Received: from top.free-electrons.com ([176.31.233.9]:40311 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751196AbaC2JTG (ORCPT ); Sat, 29 Mar 2014 05:19:06 -0400 Date: Sat, 29 Mar 2014 10:19:03 +0100 From: Thomas Petazzoni To: Boris BREZILLON Cc: Rob Landley , Nicolas Ferre , Jean-Christophe Plagniol-Villard , Thomas Gleixner , devicetree@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [RFC PATCH v2 07/10] irqchip: atmel-aic: document new dt properties and children nodes Message-ID: <20140329101903.65848c12@skate> In-Reply-To: <1396029548-10928-8-git-send-email-b.brezillon.dev@gmail.com> References: <1396029548-10928-1-git-send-email-b.brezillon.dev@gmail.com> <1396029548-10928-8-git-send-email-b.brezillon.dev@gmail.com> Organization: Free Electrons X-Mailer: Claws Mail 3.9.1 (GTK+ 2.24.20; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Dear Boris BREZILLON, On Fri, 28 Mar 2014 18:59:05 +0100, Boris BREZILLON wrote: > +Optional children nodes: > +- muxed irq entries: > + Required properties: > + * compatible: Shall be > + "atmel,aic-mux-1reg-irq": irq enable/disable/retrieve-status is done by > + setting/clearing/reading flags in a specific register > + or > + "atmel,aic-mux-3reg-irq": irq enable/disable/retrieve-status is done > + by writing/reading flags in specific enable/disable/mask registers > + * reg: encode the interrupt control register. > + The first cell encode the irq line. > + The second cell encode the offset register within its iomem range > + The last cell encode the iomem region size (should always be set to 0x4). > + * atmel,aic-mux-reg-mask: define the mask used to disable the interrupts > + generated by the muxed entry. Can you describe in more details what are these muxed irqs? Are they interrupts raised to the AIC that may actually be related to several devices, like a shared interrupt? If that's the case, then what you want is to implement separate interrupt controller drivers to handle those shared interrupts, and demux them into multiple separate interrupts. Note that the way you use the "ranges" property seems wrong to me: you're using it as a "hack" to define the base address of some peripherals that are outside the AIC, while the ranges property is normally used to describe the address translations between a child bus and a parent bus. Which is not what you have here, as far as I can understand. So could you give more details about the design of the AIC and these muxed interrupts, to see if the DT binding you're proposing is actually the right way of representing the hardware? Thomas -- Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com