All of lore.kernel.org
 help / color / mirror / Atom feed
From: lars@metafoo.de (Lars-Peter Clausen)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] pxa3xx: fix PXA GPIO IRQ handling
Date: Tue, 18 Jan 2011 12:47:12 +0100	[thread overview]
Message-ID: <4D357DC0.2030006@metafoo.de> (raw)
In-Reply-To: <1295338738-4129-1-git-send-email-s.neumann@raumfeld.com>

On 01/18/2011 09:18 AM, Sven Neumann wrote:
> From: Lars-Peter Clausen <lars@metafoo.de>
> 
> Set the "set_wake" field of the irq_chip struct before calling
> set_irq_chip() for all of the IRQs, so that the compat handler
> actually gets installed.
> 
> Tested-by: Sven Neumann <s.neumann@raumfeld.com>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>

> ---
>  arch/arm/mach-pxa/irq.c    |    7 ++++---
>  arch/arm/mach-pxa/pxa3xx.c |    4 ++--
>  2 files changed, 6 insertions(+), 5 deletions(-)
> 
> diff --git a/arch/arm/mach-pxa/irq.c b/arch/arm/mach-pxa/irq.c
> index 1beb40f..a5b42a7 100644
> --- a/arch/arm/mach-pxa/irq.c
> +++ b/arch/arm/mach-pxa/irq.c
> @@ -111,13 +111,13 @@ static void __init pxa_init_low_gpio_irq(set_wake_t fn)
>  	GRER0 &= ~0x3;
>  	GEDR0 = 0x3;
>  
> +	pxa_low_gpio_chip.set_wake = fn;
> +
>  	for (irq = IRQ_GPIO0; irq <= IRQ_GPIO1; irq++) {
>  		set_irq_chip(irq, &pxa_low_gpio_chip);
>  		set_irq_handler(irq, handle_edge_irq);
>  		set_irq_flags(irq, IRQF_VALID);
>  	}
> -
> -	pxa_low_gpio_chip.set_wake = fn;
>  }
>  
>  void __init pxa_init_irq(int irq_nr, set_wake_t fn)
> @@ -142,13 +142,14 @@ void __init pxa_init_irq(int irq_nr, set_wake_t fn)
>  	/* only unmasked interrupts kick us out of idle */
>  	ICCR = 1;
>  
> +	pxa_internal_irq_chip.set_wake = fn;
> +
>  	for (irq = PXA_IRQ(0); irq < PXA_IRQ(irq_nr); irq++) {
>  		set_irq_chip(irq, &pxa_internal_irq_chip);
>  		set_irq_handler(irq, handle_level_irq);
>  		set_irq_flags(irq, IRQF_VALID);
>  	}
>  
> -	pxa_internal_irq_chip.set_wake = fn;
>  	pxa_init_low_gpio_irq(fn);
>  }
>  
> diff --git a/arch/arm/mach-pxa/pxa3xx.c b/arch/arm/mach-pxa/pxa3xx.c
> index 276e8fb..5a8fe5c 100644
> --- a/arch/arm/mach-pxa/pxa3xx.c
> +++ b/arch/arm/mach-pxa/pxa3xx.c
> @@ -567,13 +567,13 @@ static void __init pxa_init_ext_wakeup_irq(set_wake_t fn)
>  {
>  	int irq;
>  
> +	pxa_ext_wakeup_chip.set_wake = fn;
> +
>  	for (irq = IRQ_WAKEUP0; irq <= IRQ_WAKEUP1; irq++) {
>  		set_irq_chip(irq, &pxa_ext_wakeup_chip);
>  		set_irq_handler(irq, handle_edge_irq);
>  		set_irq_flags(irq, IRQF_VALID);
>  	}
> -
> -	pxa_ext_wakeup_chip.set_wake = fn;
>  }
>  
>  void __init pxa3xx_init_irq(void)

WARNING: multiple messages have this Message-ID (diff)
From: Lars-Peter Clausen <lars@metafoo.de>
To: Sven Neumann <s.neumann@raumfeld.com>
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Daniel Mack <daniel@caiaq.de>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] pxa3xx: fix PXA GPIO IRQ handling
Date: Tue, 18 Jan 2011 12:47:12 +0100	[thread overview]
Message-ID: <4D357DC0.2030006@metafoo.de> (raw)
In-Reply-To: <1295338738-4129-1-git-send-email-s.neumann@raumfeld.com>

On 01/18/2011 09:18 AM, Sven Neumann wrote:
> From: Lars-Peter Clausen <lars@metafoo.de>
> 
> Set the "set_wake" field of the irq_chip struct before calling
> set_irq_chip() for all of the IRQs, so that the compat handler
> actually gets installed.
> 
> Tested-by: Sven Neumann <s.neumann@raumfeld.com>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>

> ---
>  arch/arm/mach-pxa/irq.c    |    7 ++++---
>  arch/arm/mach-pxa/pxa3xx.c |    4 ++--
>  2 files changed, 6 insertions(+), 5 deletions(-)
> 
> diff --git a/arch/arm/mach-pxa/irq.c b/arch/arm/mach-pxa/irq.c
> index 1beb40f..a5b42a7 100644
> --- a/arch/arm/mach-pxa/irq.c
> +++ b/arch/arm/mach-pxa/irq.c
> @@ -111,13 +111,13 @@ static void __init pxa_init_low_gpio_irq(set_wake_t fn)
>  	GRER0 &= ~0x3;
>  	GEDR0 = 0x3;
>  
> +	pxa_low_gpio_chip.set_wake = fn;
> +
>  	for (irq = IRQ_GPIO0; irq <= IRQ_GPIO1; irq++) {
>  		set_irq_chip(irq, &pxa_low_gpio_chip);
>  		set_irq_handler(irq, handle_edge_irq);
>  		set_irq_flags(irq, IRQF_VALID);
>  	}
> -
> -	pxa_low_gpio_chip.set_wake = fn;
>  }
>  
>  void __init pxa_init_irq(int irq_nr, set_wake_t fn)
> @@ -142,13 +142,14 @@ void __init pxa_init_irq(int irq_nr, set_wake_t fn)
>  	/* only unmasked interrupts kick us out of idle */
>  	ICCR = 1;
>  
> +	pxa_internal_irq_chip.set_wake = fn;
> +
>  	for (irq = PXA_IRQ(0); irq < PXA_IRQ(irq_nr); irq++) {
>  		set_irq_chip(irq, &pxa_internal_irq_chip);
>  		set_irq_handler(irq, handle_level_irq);
>  		set_irq_flags(irq, IRQF_VALID);
>  	}
>  
> -	pxa_internal_irq_chip.set_wake = fn;
>  	pxa_init_low_gpio_irq(fn);
>  }
>  
> diff --git a/arch/arm/mach-pxa/pxa3xx.c b/arch/arm/mach-pxa/pxa3xx.c
> index 276e8fb..5a8fe5c 100644
> --- a/arch/arm/mach-pxa/pxa3xx.c
> +++ b/arch/arm/mach-pxa/pxa3xx.c
> @@ -567,13 +567,13 @@ static void __init pxa_init_ext_wakeup_irq(set_wake_t fn)
>  {
>  	int irq;
>  
> +	pxa_ext_wakeup_chip.set_wake = fn;
> +
>  	for (irq = IRQ_WAKEUP0; irq <= IRQ_WAKEUP1; irq++) {
>  		set_irq_chip(irq, &pxa_ext_wakeup_chip);
>  		set_irq_handler(irq, handle_edge_irq);
>  		set_irq_flags(irq, IRQF_VALID);
>  	}
> -
> -	pxa_ext_wakeup_chip.set_wake = fn;
>  }
>  
>  void __init pxa3xx_init_irq(void)


  parent reply	other threads:[~2011-01-18 11:47 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-13 15:44 resume regression in 2.6.37 Sven Neumann
2011-01-13 15:44 ` Sven Neumann
2011-01-13 16:28 ` Thomas Gleixner
2011-01-13 16:28   ` Thomas Gleixner
2011-01-13 17:16   ` Sven Neumann
2011-01-13 17:16     ` Sven Neumann
2011-01-13 17:33     ` Thomas Gleixner
2011-01-13 17:33       ` Thomas Gleixner
2011-01-17 10:36       ` Sven Neumann
2011-01-17 10:36         ` Sven Neumann
2011-01-17 12:40         ` Thomas Gleixner
2011-01-17 12:40           ` Thomas Gleixner
2011-01-17 14:04           ` Sven Neumann
2011-01-17 14:04             ` Sven Neumann
2011-01-17 18:41             ` Thomas Gleixner
2011-01-17 18:41               ` Thomas Gleixner
2011-01-17 19:24           ` Lars-Peter Clausen
2011-01-17 19:24             ` Lars-Peter Clausen
2011-01-17 19:59             ` Lars-Peter Clausen
2011-01-17 19:59               ` Lars-Peter Clausen
2011-01-18  8:16               ` Sven Neumann
2011-01-18  8:16                 ` Sven Neumann
2011-01-18  8:18                 ` [PATCH] pxa3xx: fix PXA GPIO IRQ handling Sven Neumann
2011-01-18  8:18                   ` Sven Neumann
2011-01-18 11:06                   ` Uwe Kleine-König
2011-01-18 11:06                     ` Uwe Kleine-König
2011-01-18 11:47                   ` Lars-Peter Clausen [this message]
2011-01-18 11:47                     ` Lars-Peter Clausen
2011-01-18 12:29                     ` [PATCH] ARM: pxa: fix " Sven Neumann
2011-01-18 12:29                       ` Sven Neumann
2011-01-18 16:15                     ` [PATCH] pxa3xx: fix PXA " Eric Miao
2011-01-18 16:15                       ` Eric Miao
2011-01-18 16:20                       ` Lennert Buijtenhek
2011-01-18 16:20                         ` Lennert Buijtenhek
2011-01-18 21:49                       ` Sven Neumann
2011-01-18 21:49                         ` Sven Neumann
2011-01-20 18:48                         ` Eric Miao
2011-01-20 18:48                           ` Eric Miao
2011-01-20 18:55                           ` Eric Miao
2011-01-20 18:55                             ` Eric Miao
2011-01-18  8:19             ` resume regression in 2.6.37 Thomas Gleixner
2011-01-18  8:19               ` Thomas Gleixner

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=4D357DC0.2030006@metafoo.de \
    --to=lars@metafoo.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.