All of lore.kernel.org
 help / color / mirror / Atom feed
* [RESEND PATCH] arm: ipipe: omap-gpio: Fix interrupts delivering
@ 2021-09-26 10:07 Dario Binacchi
  2021-09-26 11:59 ` Greg Gallagher
  0 siblings, 1 reply; 3+ messages in thread
From: Dario Binacchi @ 2021-09-26 10:07 UTC (permalink / raw)
  To: xenomai; +Cc: greg, jan.kiszka, Dario Binacchi

If you set the irq trigger as edge rising or falling the interrupts are
no longer delivered to the upper layers. The gpiokeys driver, for
example, no longer detects the change in the state of the pins mapped
to the buttons.

Fixes: c041e938312b ("arm: ipipe: Fix up the omap-gpio driver to deliver interrupts properly to the pipeline")
Signed-off-by: Dario Binacchi <dariobin@libero.it>
---
 drivers/gpio/gpio-omap.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
index c8192c82d2b1..ae527d65bfc2 100644
--- a/drivers/gpio/gpio-omap.c
+++ b/drivers/gpio/gpio-omap.c
@@ -577,9 +577,6 @@ static int omap_gpio_irq_type(struct irq_data *d, unsigned type)
 	}
 	raw_spin_unlock_irqrestore(&bank->lock, flags);
 
-#ifdef CONFIG_IPIPE
-	irq_set_handler_locked(d, handle_level_irq);
-#else
 	if (type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH))
 		irq_set_handler_locked(d, handle_level_irq);
 	else if (type & (IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING))
@@ -590,7 +587,7 @@ static int omap_gpio_irq_type(struct irq_data *d, unsigned type)
 		 * So just use handle_simple_irq.
 		 */
 		irq_set_handler_locked(d, handle_simple_irq);
-#endif
+
 	return 0;
 
 error:
-- 
2.17.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [RESEND PATCH] arm: ipipe: omap-gpio: Fix interrupts delivering
  2021-09-26 10:07 [RESEND PATCH] arm: ipipe: omap-gpio: Fix interrupts delivering Dario Binacchi
@ 2021-09-26 11:59 ` Greg Gallagher
  2021-10-04  0:27   ` Greg Gallagher
  0 siblings, 1 reply; 3+ messages in thread
From: Greg Gallagher @ 2021-09-26 11:59 UTC (permalink / raw)
  To: Dario Binacchi; +Cc: jan.kiszka, xenomai

On Sun, Sep 26, 2021 at 6:07 AM Dario Binacchi <dariobin@libero.it> wrote:

> If you set the irq trigger as edge rising or falling the interrupts are
> no longer delivered to the upper layers. The gpiokeys driver, for
> example, no longer detects the change in the state of the pins mapped
> to the buttons.
>
> Fixes: c041e938312b ("arm: ipipe: Fix up the omap-gpio driver to deliver
> interrupts properly to the pipeline")
> Signed-off-by: Dario Binacchi <dariobin@libero.it>
> ---
>  drivers/gpio/gpio-omap.c | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
> index c8192c82d2b1..ae527d65bfc2 100644
> --- a/drivers/gpio/gpio-omap.c
> +++ b/drivers/gpio/gpio-omap.c
> @@ -577,9 +577,6 @@ static int omap_gpio_irq_type(struct irq_data *d,
> unsigned type)
>         }
>         raw_spin_unlock_irqrestore(&bank->lock, flags);
>
> -#ifdef CONFIG_IPIPE
> -       irq_set_handler_locked(d, handle_level_irq);
> -#else
>         if (type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH))
>                 irq_set_handler_locked(d, handle_level_irq);
>         else if (type & (IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING))
> @@ -590,7 +587,7 @@ static int omap_gpio_irq_type(struct irq_data *d,
> unsigned type)
>                  * So just use handle_simple_irq.
>                  */
>                 irq_set_handler_locked(d, handle_simple_irq);
> -#endif
> +
>         return 0;
>
>  error:
> --
> 2.17.1


Thanks, applying to 5.4 and 4.19. I’ll have a. Updated release this week.

Thanks

Greg

>
>
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [RESEND PATCH] arm: ipipe: omap-gpio: Fix interrupts delivering
  2021-09-26 11:59 ` Greg Gallagher
@ 2021-10-04  0:27   ` Greg Gallagher
  0 siblings, 0 replies; 3+ messages in thread
From: Greg Gallagher @ 2021-10-04  0:27 UTC (permalink / raw)
  To: Dario Binacchi; +Cc: Jan Kiszka, Xenomai@xenomai.org

On Sun, Sep 26, 2021 at 7:59 AM Greg Gallagher <greg@embeddedgreg.com>
wrote:

>
>
> On Sun, Sep 26, 2021 at 6:07 AM Dario Binacchi <dariobin@libero.it> wrote:
>
>> If you set the irq trigger as edge rising or falling the interrupts are
>> no longer delivered to the upper layers. The gpiokeys driver, for
>> example, no longer detects the change in the state of the pins mapped
>> to the buttons.
>>
>> Fixes: c041e938312b ("arm: ipipe: Fix up the omap-gpio driver to deliver
>> interrupts properly to the pipeline")
>> Signed-off-by: Dario Binacchi <dariobin@libero.it>
>> ---
>>  drivers/gpio/gpio-omap.c | 5 +----
>>  1 file changed, 1 insertion(+), 4 deletions(-)
>>
>> diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
>> index c8192c82d2b1..ae527d65bfc2 100644
>> --- a/drivers/gpio/gpio-omap.c
>> +++ b/drivers/gpio/gpio-omap.c
>> @@ -577,9 +577,6 @@ static int omap_gpio_irq_type(struct irq_data *d,
>> unsigned type)
>>         }
>>         raw_spin_unlock_irqrestore(&bank->lock, flags);
>>
>> -#ifdef CONFIG_IPIPE
>> -       irq_set_handler_locked(d, handle_level_irq);
>> -#else
>>         if (type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH))
>>                 irq_set_handler_locked(d, handle_level_irq);
>>         else if (type & (IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING))
>> @@ -590,7 +587,7 @@ static int omap_gpio_irq_type(struct irq_data *d,
>> unsigned type)
>>                  * So just use handle_simple_irq.
>>                  */
>>                 irq_set_handler_locked(d, handle_simple_irq);
>> -#endif
>> +
>>         return 0;
>>
>>  error:
>> --
>> 2.17.1
>
>
> Thanks, applying to 5.4 and 4.19. I’ll have a. Updated release this week.
>
> Thanks
>
> Greg
>
>>
>>
>> Applied to master, starting the 4.19 and 5.4 update.

Thanks

-Greg

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-10-04  0:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-26 10:07 [RESEND PATCH] arm: ipipe: omap-gpio: Fix interrupts delivering Dario Binacchi
2021-09-26 11:59 ` Greg Gallagher
2021-10-04  0:27   ` Greg Gallagher

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.