devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Simon Horman <horms@verge.net.au>
To: Arnd Bergmann <arnd@arndb.de>
Cc: linux-arm-kernel@lists.infradead.org,
	Mark Rutland <mark.rutland@arm.com>,
	Simon Horman <horms+renesas@verge.net.au>,
	"linux-sh@vger.kernel.org" <linux-sh@vger.kernel.org>,
	"devicetree-discuss@lists.ozlabs.org"
	<devicetree-discuss@lists.ozlabs.org>,
	Magnus Damm <magnus.damm@gmail.com>,
	Bastian Hecht <hechtb@gmail.com>,
	Magnus Damm <damm@opensource.se>,
	Paul Mundt <lethal@linux-sh.org>,
	Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>,
	Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Subject: Re: [PATCH 1/8] SH: intc: Add support OF for INTC
Date: Thu, 17 Jan 2013 15:20:29 +0900	[thread overview]
Message-ID: <20130117062029.GA26725@verge.net.au> (raw)
In-Reply-To: <20130110015651.GJ21832@verge.net.au>

On Thu, Jan 10, 2013 at 10:56:51AM +0900, Simon Horman wrote:
> On Wed, Jan 09, 2013 at 07:11:04PM +0000, Arnd Bergmann wrote:
> > On Wednesday 09 January 2013, Mark Rutland wrote:
> > > Hi,
> > > 
> > > Thanks for updating the text, this is far easier to read than previously.
> > > 
> > > However, I'm still concerned by how complex the binding seems. As I don't have
> > > any familiarity with the device, I don't know whether that's just an artifact
> > > of the hardware or something that can be cleared up.
> > > 
> > > I think the approach used by the binding needs some serious review before this
> > > should be merged. It seems far more complex than any existing interrupt
> > > controller binding. Without a dts example for a complete board (complete with
> > > devices wired up to the interrupt controller), it's difficult to judge how this
> > > will work in practice.
> > > 
> > > I've added Arnd to Cc in case he has any thoughts on the matter.
> > 
> > Sorry for having been absent from this discussion for so long. I didn't
> > realize there were 9 versions of this patch set.
> > 
> > I tend to agree with your interpretation above, but I may be missing
> > important facts from the previous review rounds.
> > 
> > For all I can tell, the binding is an attempt to describe the
> > entire drivers/sh/intc capabilities, which is probably not the
> > best way to approach things. The sh intc driver is not just an
> > irqchip driver, but rather a framework to describe arbitrary
> > irqchips, which is what makes this so hard.
> > 
> > When I first looked at the situation last year, I suggested doing
> > a new irqchip driver with a much simpler binding that can only
> > handle the irq chips from shmobile, rather than the whole thing.
> > 
> > I am not sure if the binding in the current form is already the
> > "simplified" version, or if it actually implements all the
> > capabilities of the intc driver.
> 
> I think its more on the side of implementing the capabilities of
> the intc driver than being simplified.
> 
> Although some effort has gone into this patchset my primary
> aim is to provide something that provides the basis for supporting
> the INTC controller on all existing boards.
> 
> I more than open to concrete ideas of how this can be achieved in agreeable way.
> 
> > > > +       intca: interrupt-controller@0 {
> > > > +               compatible = "renesas,sh_intc";
> > > > +               interrupt-controller;
> > > > +               #address-cells = <1>;
> > > > +               #size-cells = <1>;
> > > > +               #interrupt-cells = <1>;
> > > > +               ranges;
> > > > +
> > > > +               reg = <0xe6940000 0x200>, <0xe6950000 0x200>;
> > > > +               group_size = <19>;
> > > > +
> > > > +               DIRC: intsrc1 { vector = <0x0560>; };
> > > > +               ATAPI: intsrc2 { vector = <0x05E0>; };
> > > 
> > > This looks suspiciously like a way of encoding a device's interrupt information
> > > into the interrupt controller's device node. That strikes me as being the wrong
> > > way round.
> > 
> > Agreed, it would be simpler to have e.g. #interrupt-cells = <4>, to describe
> > the various offsets when needed (I forgot how many are actually required
> > in practice, rather than being computable from the other numbers), and
> > possibly a global interrupt-map/interrupt-map-mask property pair to map
> > this into a flat number space.
> 
> I'm not sure that I see what you are getting at here.
> 
> > I need to take some more time to understand the actual requirements again,
> > but IIRC it would be possible to do something much simpler than the
> > proposed binding.

Ping

  reply	other threads:[~2013-01-17  6:20 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-09  6:29 [RFC v9 0/8] ARM: shmobile: DT initialisation of INTC Simon Horman
2013-01-09  6:30 ` [PATCH 1/8] SH: intc: Add support OF for INTC Simon Horman
2013-01-09 11:53   ` Mark Rutland
2013-01-09 19:11     ` Arnd Bergmann
2013-01-10  1:56       ` Simon Horman
2013-01-17  6:20         ` Simon Horman [this message]
2013-01-10  1:58     ` Simon Horman
2013-01-10  8:42     ` Magnus Damm
2013-01-09  6:30 ` [PATCH 2/8] ARM: shmobile: Add support OF of INTC for r8a7740 Simon Horman
2013-01-09  6:30 ` [PATCH 3/8] ARM: shmobile: Add support OF of INTC for sh7372 Simon Horman
2013-01-09 11:17   ` Mark Rutland
2013-01-10  8:34     ` Magnus Damm
2013-01-09  6:30 ` [PATCH 4/8] ARM: shmobile: Add DT table " Simon Horman
2013-01-09  6:30 ` [PATCH 5/8] ARM: shmobile: Add DT table of INTC for r8a7740 Simon Horman
2013-01-09  6:30 ` [PATCH 6/8] ARM: shmobile: r8a7740: Use DT initialisation of INTC Simon Horman
2013-01-09  6:30 ` [PATCH 7/8] ARM: shmobile: sh7372: Do not initialise TMU when using DT Simon Horman
2013-01-09  6:30 ` [PATCH 8/8] ARM: shmobile: sh7372: Use DT initialisation of INTC Simon Horman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130117062029.GA26725@verge.net.au \
    --to=horms@verge.net.au \
    --cc=arnd@arndb.de \
    --cc=damm@opensource.se \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=g.liakhovetski@gmx.de \
    --cc=hechtb@gmail.com \
    --cc=horms+renesas@verge.net.au \
    --cc=lethal@linux-sh.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=mark.rutland@arm.com \
    --cc=nobuhiro.iwamatsu.yj@renesas.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).