Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-09-19 Thread Dmitry Torokhov
On Tue, Sep 18, 2012 at 01:22:06PM +0200, Linus Walleij wrote: > On Fri, Sep 14, 2012 at 10:03 AM, Lee Jones wrote: > > On Thu, Sep 13, 2012 at 11:35:43AM +0200, Linus Walleij wrote: > >> > >> Not having this patch in v3.6-rcN gives the following boot noise (and > >> the key does not work): > >> >

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-09-18 Thread Linus Walleij
On Fri, Sep 14, 2012 at 10:03 AM, Lee Jones wrote: > On Thu, Sep 13, 2012 at 11:35:43AM +0200, Linus Walleij wrote: >> >> Not having this patch in v3.6-rcN gives the following boot noise (and >> the key does not work): >> >> [ cut here ] >> WARNING: at /home/elinwal/linux-s

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-09-14 Thread Lee Jones
On Thu, Sep 13, 2012 at 11:35:43AM +0200, Linus Walleij wrote: > On Mon, Aug 6, 2012 at 2:32 PM, Lee Jones wrote: > > > If we're booting with Device Tree enabled, we want the IRQ numbers to > > be taken and translated from the Device Tree binary. If not, they > > should be taken from the resource

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-09-13 Thread Linus Walleij
On Mon, Aug 6, 2012 at 2:32 PM, Lee Jones wrote: > If we're booting with Device Tree enabled, we want the IRQ numbers to > be taken and translated from the Device Tree binary. If not, they > should be taken from the resource allocation defined in the AB8500 MFD > core driver. > > Tested-by: Linus

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Mark Brown
On Wed, Aug 08, 2012 at 12:40:38PM +0100, Lee Jones wrote: > On Wed, Aug 08, 2012 at 10:49:52AM +0100, Mark Brown wrote: > > > - MFD adds the IRQ base to the hwirq and registers it as a virq > > Just don't do this step - the only reason to do it is for mapping back > > into a linear domain but i

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Lee Jones
On Wed, Aug 08, 2012 at 10:49:52AM +0100, Mark Brown wrote: > On Wed, Aug 08, 2012 at 09:04:12AM +0100, Lee Jones wrote: > > > During non-DT boot: > > - Platform data is passed, which contains an IRQ base > > - If an IRQ base is requested we use it to register a Legacy IRQ Domain > > - MFD adds

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Mark Brown
On Wed, Aug 08, 2012 at 08:28:35AM +, Arnd Bergmann wrote: > In general, it seems easier to use the same domain type for both cases. > I don't think that MOP500_AB8500_VIR_GPIO_IRQ_BASE is used anywhere > else besides the .irq_base definition in board-mop500.c, so I would guess > that you can

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Mark Brown
On Wed, Aug 08, 2012 at 09:04:12AM +0100, Lee Jones wrote: > During non-DT boot: > - Platform data is passed, which contains an IRQ base > - If an IRQ base is requested we use it to register a Legacy IRQ Domain > - MFD adds the IRQ base to the hwirq and registers it as a virq Just don't do thi

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Arnd Bergmann
On Wednesday 08 August 2012, Lee Jones wrote: > Okay, actually this isn't so easy. Currently we have: > > During DT boot: > - No platform data is passed, hence no IRQ base for AB8500 is either > - No IRQ base means we register a Linear IRQ Domain > - MFD sees there is no base and leaves the IRQ

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Lee Jones
On Tue, Aug 07, 2012 at 06:03:34PM +0100, Mark Brown wrote: > On Tue, Aug 07, 2012 at 06:01:30PM +0100, Lee Jones wrote: > > > Okay, so I've just spent a small amount of time looking at this. I think > > the best place for this would be in *_get_virq(), using the same logic that > > selected a *_l

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-08 Thread Lee Jones
> Restating my comment elsewhere... why do we even need to do this in > _get_virq() - I'd *really* expect this to be handled by the irq domain > code. > > Okay, so I've just spent a small amount of time looking at this. I think > > the best place for this would be in *_get_virq(), using the same

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-07 Thread Mark Brown
On Tue, Aug 07, 2012 at 06:01:30PM +0100, Lee Jones wrote: > Okay, so I've just spent a small amount of time looking at this. I think > the best place for this would be in *_get_virq(), using the same logic that > selected a *_legacy or *_linear domain in the first place. The only thing > the dom

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-07 Thread Lee Jones
On Mon, Aug 06, 2012 at 05:02:26PM +0100, Mark Brown wrote: > On Mon, Aug 06, 2012 at 04:37:52PM +0100, Lee Jones wrote: > > On Mon, Aug 06, 2012 at 01:19:15AM -0700, Dmitry Torokhov wrote: > > > > > + ponkey->irq_dbf = (np) ? ab8500_irq_get_virq(ab8500, irq_dbf) : > > > > irq_dbf; > > > >

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-06 Thread Lee Jones
On Mon, Aug 06, 2012 at 05:02:26PM +0100, Mark Brown wrote: > On Mon, Aug 06, 2012 at 04:37:52PM +0100, Lee Jones wrote: > > On Mon, Aug 06, 2012 at 01:19:15AM -0700, Dmitry Torokhov wrote: > > > > > + ponkey->irq_dbf = (np) ? ab8500_irq_get_virq(ab8500, irq_dbf) : > > > > irq_dbf; > > > >

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-06 Thread Mark Brown
On Mon, Aug 06, 2012 at 04:37:52PM +0100, Lee Jones wrote: > On Mon, Aug 06, 2012 at 01:19:15AM -0700, Dmitry Torokhov wrote: > > > + ponkey->irq_dbf = (np) ? ab8500_irq_get_virq(ab8500, irq_dbf) : irq_dbf; > > > + ponkey->irq_dbr = (np) ? ab8500_irq_get_virq(ab8500, irq_dbr) : irq_dbr; > > Why t

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-06 Thread Lee Jones
On Mon, Aug 06, 2012 at 01:19:15AM -0700, Dmitry Torokhov wrote: > > - ponkey->irq_dbf = ab8500_irq_get_virq(ab8500, irq_dbf); > > - ponkey->irq_dbr = ab8500_irq_get_virq(ab8500, irq_dbr); > > + > > + ponkey->irq_dbf = (np) ? ab8500_irq_get_virq(ab8500, irq_dbf) : irq_dbf; > > + ponkey->irq

Re: [PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-06 Thread Dmitry Torokhov
Hi Lee, On Mon, Aug 06, 2012 at 01:32:03PM +0100, Lee Jones wrote: > If we're booting with Device Tree enabled, we want the IRQ numbers to > be taken and translated from the Device Tree binary. If not, they > should be taken from the resource allocation defined in the AB8500 MFD > core driver. >

[PATCH 1/1] Input: ab8500-ponkey: Make the distinction between DT and non-DT boots

2012-08-06 Thread Lee Jones
If we're booting with Device Tree enabled, we want the IRQ numbers to be taken and translated from the Device Tree binary. If not, they should be taken from the resource allocation defined in the AB8500 MFD core driver. Tested-by: Linus Walleij Signed-off-by: Lee Jones --- drivers/input/misc/ab