[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20111123050012.GS19069@tbergstrom-lnx.Nvidia.com>
Date: Wed, 23 Nov 2011 07:00:12 +0200
From: Peter De Schrijver <pdeschrijver@...dia.com>
To: Stephen Warren <swarren@...dia.com>
CC: Russell King <linux@....linux.org.uk>,
Colin Cross <ccross@...roid.com>,
Olof Johansson <olof@...om.net>,
Marc Dietrich <marvin24@....de>,
"Grant Likely" <grant.likely@...retlab.ca>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-tegra@...r.kernel.org" <linux-tegra@...r.kernel.org>,
"devicetree-discuss@...ts.ozlabs.org"
<devicetree-discuss@...ts.ozlabs.org>
Subject: Re: [PATCH] arm/tegra: convert tegra20 to GIC devicetree binding
> > > But the WM8903 still has the same interrupt-parent as everything else,
> > > since it's inherited from /interrupt-parent and doesn't define its own.
> > > Perhaps this is a mistake?
> >
> > Yes. I think this is a mistake. If we want the device tree to reflect the
> > hardware, I think the WM8903 node should specify the GPIO, not the IRQ
> > number.
>
> Hmm. This somewhat goes back to the previous irq_to_gpio discussion...
>
> The WM8903 driver only cares about having an interrupt. In this case at
> least, the driver never performs any GPIO-like manipulation on this
> interrupt line. As such, shouldn't the driver receive the interrupt ID
> to use?
>
Maybe it should then. I guess also edge vs level and polarity need to be
specified?
> The rationale here is that while the WM8903's interrupt output is hooked
> to a GPIO input on Tegra systems, there's no reason to believe that it
> couldn't be hooked to a dedicated interrupt input pin on some other SoC
> (i.e. not a GPIO). In that case, there'd be no GPIO to pass to the driver.
>
> Now perhaps what this means is that we need a DT binding for "the IRQ
> generated by this given GPIO pin", rather than encoding that interrupt
> number into the WM8903 node directly? That's certainly exactly what we
> do when creating the platform data in board files in this case.
I think we need to model the GPIO IRQs as a seperate interrupt controller.
That way the WM8903 node can refer to the GPIO IRQ as an IRQ without
hardcoding the global interrupt number, similar to the way we specify the
SPI number in the device nodes and not the global interrupt number.
Cheers,
Peter.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists