* [PATCH] i2c: imx: Clean up a call to request_irq()
@ 2023-07-25 6:50 Dan Carpenter
2023-07-25 7:36 ` Uwe Kleine-König
2023-08-02 20:10 ` Andi Shyti
0 siblings, 2 replies; 5+ messages in thread
From: Dan Carpenter @ 2023-07-25 6:50 UTC (permalink / raw)
To: Oleksij Rempel
Cc: Pengutronix Kernel Team, Andi Shyti, Shawn Guo, Sascha Hauer,
Fabio Estevam, NXP Linux Team, linux-i2c, kernel-janitors
This is passing a NULL thread to request_threaded_irq(). So it's not
really a threaded IRQ at all. It's more readable to call request_irq()
instead.
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
drivers/i2c/busses/i2c-imx.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c
index 65128a73e8a3..c0cac5bcfdd1 100644
--- a/drivers/i2c/busses/i2c-imx.c
+++ b/drivers/i2c/busses/i2c-imx.c
@@ -1506,8 +1506,7 @@ static int i2c_imx_probe(struct platform_device *pdev)
goto rpm_disable;
/* Request IRQ */
- ret = request_threaded_irq(irq, i2c_imx_isr, NULL, IRQF_SHARED,
- pdev->name, i2c_imx);
+ ret = request_irq(irq, i2c_imx_isr, IRQF_SHARED, pdev->name, i2c_imx);
if (ret) {
dev_err(&pdev->dev, "can't claim irq %d\n", irq);
goto rpm_disable;
--
2.39.2
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] i2c: imx: Clean up a call to request_irq()
2023-07-25 6:50 [PATCH] i2c: imx: Clean up a call to request_irq() Dan Carpenter
@ 2023-07-25 7:36 ` Uwe Kleine-König
2023-07-25 7:42 ` Dan Carpenter
2023-08-02 20:10 ` Andi Shyti
1 sibling, 1 reply; 5+ messages in thread
From: Uwe Kleine-König @ 2023-07-25 7:36 UTC (permalink / raw)
To: Dan Carpenter
Cc: Oleksij Rempel, Andi Shyti, Shawn Guo, Sascha Hauer,
kernel-janitors, NXP Linux Team, Pengutronix Kernel Team,
Fabio Estevam, linux-i2c
[-- Attachment #1: Type: text/plain, Size: 1533 bytes --]
Hello Dan,
On Tue, Jul 25, 2023 at 09:50:55AM +0300, Dan Carpenter wrote:
> This is passing a NULL thread to request_threaded_irq(). So it's not
> really a threaded IRQ at all. It's more readable to call request_irq()
> instead.
>
> Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
> ---
> drivers/i2c/busses/i2c-imx.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c
> index 65128a73e8a3..c0cac5bcfdd1 100644
> --- a/drivers/i2c/busses/i2c-imx.c
> +++ b/drivers/i2c/busses/i2c-imx.c
> @@ -1506,8 +1506,7 @@ static int i2c_imx_probe(struct platform_device *pdev)
> goto rpm_disable;
>
> /* Request IRQ */
> - ret = request_threaded_irq(irq, i2c_imx_isr, NULL, IRQF_SHARED,
> - pdev->name, i2c_imx);
> + ret = request_irq(irq, i2c_imx_isr, IRQF_SHARED, pdev->name, i2c_imx);
> if (ret) {
> dev_err(&pdev->dev, "can't claim irq %d\n", irq);
> goto rpm_disable;
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
There are a few more drivers that could benefit from the same patch
(i.e.
drivers/gpu/drm/bridge/samsung-dsim.c
drivers/iio/magnetometer/bmc150_magn.c
drivers/scsi/mpi3mr/mpi3mr_fw.c
drivers/spi/spi-fsl-dspi.c
as of today's next).
I assume you care for these, too?
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] i2c: imx: Clean up a call to request_irq()
2023-07-25 7:36 ` Uwe Kleine-König
@ 2023-07-25 7:42 ` Dan Carpenter
0 siblings, 0 replies; 5+ messages in thread
From: Dan Carpenter @ 2023-07-25 7:42 UTC (permalink / raw)
To: Uwe Kleine-König
Cc: Oleksij Rempel, Andi Shyti, Shawn Guo, Sascha Hauer,
kernel-janitors, NXP Linux Team, Pengutronix Kernel Team,
Fabio Estevam, linux-i2c
On Tue, Jul 25, 2023 at 09:36:29AM +0200, Uwe Kleine-König wrote:
> Hello Dan,
>
> On Tue, Jul 25, 2023 at 09:50:55AM +0300, Dan Carpenter wrote:
> > This is passing a NULL thread to request_threaded_irq(). So it's not
> > really a threaded IRQ at all. It's more readable to call request_irq()
> > instead.
> >
> > Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
> > ---
> > drivers/i2c/busses/i2c-imx.c | 3 +--
> > 1 file changed, 1 insertion(+), 2 deletions(-)
> >
> > diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c
> > index 65128a73e8a3..c0cac5bcfdd1 100644
> > --- a/drivers/i2c/busses/i2c-imx.c
> > +++ b/drivers/i2c/busses/i2c-imx.c
> > @@ -1506,8 +1506,7 @@ static int i2c_imx_probe(struct platform_device *pdev)
> > goto rpm_disable;
> >
> > /* Request IRQ */
> > - ret = request_threaded_irq(irq, i2c_imx_isr, NULL, IRQF_SHARED,
> > - pdev->name, i2c_imx);
> > + ret = request_irq(irq, i2c_imx_isr, IRQF_SHARED, pdev->name, i2c_imx);
> > if (ret) {
> > dev_err(&pdev->dev, "can't claim irq %d\n", irq);
> > goto rpm_disable;
>
> Reviewed-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
>
> There are a few more drivers that could benefit from the same patch
> (i.e.
> drivers/gpu/drm/bridge/samsung-dsim.c
> drivers/iio/magnetometer/bmc150_magn.c
> drivers/scsi/mpi3mr/mpi3mr_fw.c
> drivers/spi/spi-fsl-dspi.c
> as of today's next).
>
> I assume you care for these, too?
>
I had a couple more I was planning to send. I was sending them slowly
to see if people wanted to make them into threaded IRQs instead of
officially making them unthreaded.
regards,
dan carpenter
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] i2c: imx: Clean up a call to request_irq()
2023-07-25 6:50 [PATCH] i2c: imx: Clean up a call to request_irq() Dan Carpenter
2023-07-25 7:36 ` Uwe Kleine-König
@ 2023-08-02 20:10 ` Andi Shyti
2023-08-14 15:08 ` Wolfram Sang
1 sibling, 1 reply; 5+ messages in thread
From: Andi Shyti @ 2023-08-02 20:10 UTC (permalink / raw)
To: Oleksij Rempel, Dan Carpenter
Cc: Andi Shyti, Pengutronix Kernel Team, Shawn Guo, Sascha Hauer,
Fabio Estevam, NXP Linux Team, linux-i2c, kernel-janitors
Hi
On Tue, 25 Jul 2023 09:50:55 +0300, Dan Carpenter wrote:
> This is passing a NULL thread to request_threaded_irq(). So it's not
> really a threaded IRQ at all. It's more readable to call request_irq()
> instead.
>
>
Applied to i2c/andi-for-next on
https://git.kernel.org/pub/scm/linux/kernel/git/andi.shyti/linux.git
Please note that this patch may still undergo further evaluation
and the final decision will be made in collaboration with
Wolfram.
Thank you,
Andi
Patches applied
===============
[1/1] i2c: imx: Clean up a call to request_irq()
commit: b4fd609a2018bb0bfce9351c506a6e0dc7fb64e8
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] i2c: imx: Clean up a call to request_irq()
2023-08-02 20:10 ` Andi Shyti
@ 2023-08-14 15:08 ` Wolfram Sang
0 siblings, 0 replies; 5+ messages in thread
From: Wolfram Sang @ 2023-08-14 15:08 UTC (permalink / raw)
To: Andi Shyti
Cc: Oleksij Rempel, Dan Carpenter, Pengutronix Kernel Team, Shawn Guo,
Sascha Hauer, Fabio Estevam, NXP Linux Team, linux-i2c,
kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 402 bytes --]
On Wed, Aug 02, 2023 at 10:10:32PM +0200, Andi Shyti wrote:
> Hi
>
> On Tue, 25 Jul 2023 09:50:55 +0300, Dan Carpenter wrote:
> > This is passing a NULL thread to request_threaded_irq(). So it's not
> > really a threaded IRQ at all. It's more readable to call request_irq()
> > instead.
> >
> >
>
> Applied to i2c/andi-for-next on
Applied to for-next (via Andi's branch), thanks!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-08-14 15:10 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-25 6:50 [PATCH] i2c: imx: Clean up a call to request_irq() Dan Carpenter
2023-07-25 7:36 ` Uwe Kleine-König
2023-07-25 7:42 ` Dan Carpenter
2023-08-02 20:10 ` Andi Shyti
2023-08-14 15:08 ` Wolfram Sang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox