linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] iio: exynos-adc: fix irqf_oneshot.cocci warnings
@ 2015-12-02  8:43 Valentin Rothberg
  2015-12-22  5:09 ` Olof Johansson
  0 siblings, 1 reply; 2+ messages in thread
From: Valentin Rothberg @ 2015-12-02  8:43 UTC (permalink / raw)
  To: arnd; +Cc: fengguang.wu, arm, linux-kernel

Since commit 1c6c69525b40 ("genirq: Reject bogus threaded irq requests")
threaded IRQs without a primary handler need to be requested with
IRQF_ONESHOT, otherwise the request will fail.

So pass the IRQF_ONESHOT flag in this case.

Generated by: scripts/coccinelle/misc/irqf_oneshot.cocci

Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com>
---

The patch looks fine to me: bad things can happen when interrupts are
acked before the handler ran.

 exynos_adc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/iio/adc/exynos_adc.c
+++ b/drivers/iio/adc/exynos_adc.c
@@ -739,7 +739,7 @@ static int exynos_adc_ts_init(struct exy
 
 	disable_irq(info->tsirq);
 	ret = request_threaded_irq(info->tsirq, NULL, exynos_ts_isr,
-				   0, "touchscreen", info);
+				   IRQF_ONESHOT, "touchscreen", info);
 	if (ret)
 		input_unregister_device(info->input);
 


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

* Re: [PATCH] iio: exynos-adc: fix irqf_oneshot.cocci warnings
  2015-12-02  8:43 [PATCH] iio: exynos-adc: fix irqf_oneshot.cocci warnings Valentin Rothberg
@ 2015-12-22  5:09 ` Olof Johansson
  0 siblings, 0 replies; 2+ messages in thread
From: Olof Johansson @ 2015-12-22  5:09 UTC (permalink / raw)
  To: Valentin Rothberg; +Cc: arnd, fengguang.wu, arm, linux-kernel, dmitry.torokhov

On Wed, Dec 02, 2015 at 09:43:10AM +0100, Valentin Rothberg wrote:
> Since commit 1c6c69525b40 ("genirq: Reject bogus threaded irq requests")
> threaded IRQs without a primary handler need to be requested with
> IRQF_ONESHOT, otherwise the request will fail.
> 
> So pass the IRQF_ONESHOT flag in this case.
> 
> Generated by: scripts/coccinelle/misc/irqf_oneshot.cocci
> 
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com>
> ---
> 
> The patch looks fine to me: bad things can happen when interrupts are
> acked before the handler ran.

Hi,

Applied. Thanks.


-Olof

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

end of thread, other threads:[~2015-12-22 19:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-12-02  8:43 [PATCH] iio: exynos-adc: fix irqf_oneshot.cocci warnings Valentin Rothberg
2015-12-22  5:09 ` Olof Johansson

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).