* [Patch] :Fix ISR return value in i2c-mpc.c
@ 2014-12-12 8:08 Amit Tomar
2014-12-12 10:50 ` Alexander Graf
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Amit Tomar @ 2014-12-12 8:08 UTC (permalink / raw)
To: linuxppc-dev@lists.ozlabs.org; +Cc: agraf@suse.de
[-- Attachment #1: Type: text/plain, Size: 782 bytes --]
ISR should return IRQ_HANDLED only in case of handling something.
Signed-off-by: Amit Singh Tomar <amit.tomar@freescale.com>
---
drivers/i2c/busses/i2c-mpc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 0edf630..7a3136f 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -95,8 +95,9 @@ static irqreturn_t mpc_i2c_isr(int irq, void *dev_id)
i2c->interrupt = readb(i2c->base + MPC_I2C_SR);
writeb(0, i2c->base + MPC_I2C_SR);
wake_up(&i2c->queue);
+ return IRQ_HANDLED;
}
- return IRQ_HANDLED;
+ return IRQ_NONE;
}
/* Sometimes 9th clock pulse isn't generated, and slave doesn't release
--
1.7.9.5
[-- Attachment #2: Type: text/html, Size: 3559 bytes --]
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Patch] :Fix ISR return value in i2c-mpc.c
2014-12-12 8:08 [Patch] :Fix ISR return value in i2c-mpc.c Amit Tomar
@ 2014-12-12 10:50 ` Alexander Graf
2014-12-12 10:52 ` Alexander Graf
2014-12-12 11:17 ` Amit Tomar
2 siblings, 0 replies; 6+ messages in thread
From: Alexander Graf @ 2014-12-12 10:50 UTC (permalink / raw)
To: Amit Tomar; +Cc: linuxppc-dev@lists.ozlabs.org
[-- Attachment #1: Type: text/plain, Size: 291 bytes --]
> Am 12.12.2014 um 09:08 schrieb Amit Tomar <Amit.Tomar@freescale.com>:
>
> ISR should return IRQ_HANDLED only in case of handling something.
>
>
> Signed-off-by: Amit Singh Tomar <amit.tomar@freescale.com>
Please just send a v2 of your patch with the below fix included :).
Alex
[-- Attachment #2: Type: text/html, Size: 2094 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Patch] :Fix ISR return value in i2c-mpc.c
2014-12-12 8:08 [Patch] :Fix ISR return value in i2c-mpc.c Amit Tomar
2014-12-12 10:50 ` Alexander Graf
@ 2014-12-12 10:52 ` Alexander Graf
2014-12-12 11:17 ` Amit Tomar
2 siblings, 0 replies; 6+ messages in thread
From: Alexander Graf @ 2014-12-12 10:52 UTC (permalink / raw)
To: Amit Tomar; +Cc: linuxppc-dev@lists.ozlabs.org
[-- Attachment #1: Type: text/plain, Size: 413 bytes --]
> Am 12.12.2014 um 09:08 schrieb Amit Tomar <Amit.Tomar@freescale.com>:
>
> ISR should return IRQ_HANDLED only in case of handling something.
>
>
> Signed-off-by: Amit Singh Tomar <amit.tomar@freescale.com>
Oh, this is on the Linux side. Sorry, please ignore my previous email.
Please provide some information on what breakage you're fixing with the patch in the patch description.
Alex
[-- Attachment #2: Type: text/html, Size: 2233 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [Patch] :Fix ISR return value in i2c-mpc.c
2014-12-12 8:08 [Patch] :Fix ISR return value in i2c-mpc.c Amit Tomar
2014-12-12 10:50 ` Alexander Graf
2014-12-12 10:52 ` Alexander Graf
@ 2014-12-12 11:17 ` Amit Tomar
2014-12-12 21:10 ` Scott Wood
2 siblings, 1 reply; 6+ messages in thread
From: Amit Tomar @ 2014-12-12 11:17 UTC (permalink / raw)
To: linuxppc-dev@lists.ozlabs.org; +Cc: agraf@suse.de
In current scenario, ISR of i2c-mpc.c is returning IRQ_HANDLED for doing no=
thing which is not right .
With below patch ISR now return IRQ_NONE for doing nothing and IRQ_HANDLED =
for doing handler work.
Signed-off-by: Amit Singh Tomar <amit.tomar@freescale.com>
---
drivers/i2c/busses/i2c-mpc.c |=A0=A0=A0 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 0edf630..7a3136f 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -95,8 +95,9 @@ static irqreturn_t mpc_i2c_isr(int irq, void *dev_id)
=A0=A0=A0=A0=A0=A0=A0 i2c->interrupt =3D readb(i2c->base + MPC_I2C_SR);
=A0=A0=A0=A0=A0=A0=A0 writeb(0, i2c->base + MPC_I2C_SR);
=A0=A0=A0=A0=A0=A0=A0 wake_up(&i2c->queue);
+=A0=A0 =A0=A0 return IRQ_HANDLED;
=A0=A0=A0 }
-=A0 return IRQ_HANDLED;
+ =A0return IRQ_NONE;
}
/* Sometimes 9th clock pulse isn't generated, and slave doesn't release
--=20
1.7.9.5
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Patch] :Fix ISR return value in i2c-mpc.c
2014-12-12 11:17 ` Amit Tomar
@ 2014-12-12 21:10 ` Scott Wood
2014-12-13 5:02 ` Amit Tomar
0 siblings, 1 reply; 6+ messages in thread
From: Scott Wood @ 2014-12-12 21:10 UTC (permalink / raw)
To: Amit Tomar; +Cc: linuxppc-dev@lists.ozlabs.org, agraf@suse.de
On Fri, 2014-12-12 at 11:17 +0000, Amit Tomar wrote:
> In current scenario, ISR of i2c-mpc.c is returning IRQ_HANDLED for doing nothing which is not right .
>
> With below patch ISR now return IRQ_NONE for doing nothing and IRQ_HANDLED for doing handler work.
Wrap the commit message at around 65-70 characters, change the subject
to "[PATCH] i2c/mpc: Fix ISR return value", and send to the proper
mailing list/maintainers for i2c (see the MAINTAINERS file).
-Scott
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Patch] :Fix ISR return value in i2c-mpc.c
2014-12-12 21:10 ` Scott Wood
@ 2014-12-13 5:02 ` Amit Tomar
0 siblings, 0 replies; 6+ messages in thread
From: Amit Tomar @ 2014-12-13 5:02 UTC (permalink / raw)
To: Scott Wood; +Cc: linuxppc-dev@lists.ozlabs.org, agraf@suse.de
Sorry for sending it to wrong mailing-list :(=0A=
=0A=
Thanks,=0A=
Amit.=0A=
________________________________________=0A=
From: Wood Scott-B07421=0A=
Sent: Saturday, December 13, 2014 2:40 AM=0A=
To: Tomar Amit-B51888=0A=
Cc: linuxppc-dev@lists.ozlabs.org; agraf@suse.de=0A=
Subject: Re: [Patch] :Fix ISR return value in i2c-mpc.c=0A=
=0A=
On Fri, 2014-12-12 at 11:17 +0000, Amit Tomar wrote:=0A=
> In current scenario, ISR of i2c-mpc.c is returning IRQ_HANDLED for doing =
nothing which is not right .=0A=
>=0A=
> With below patch ISR now return IRQ_NONE for doing nothing and IRQ_HANDLE=
D for doing handler work.=0A=
=0A=
Wrap the commit message at around 65-70 characters, change the subject=0A=
to "[PATCH] i2c/mpc: Fix ISR return value", and send to the proper=0A=
mailing list/maintainers for i2c (see the MAINTAINERS file).=0A=
=0A=
-Scott=0A=
=0A=
=0A=
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-12-13 5:02 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-12 8:08 [Patch] :Fix ISR return value in i2c-mpc.c Amit Tomar
2014-12-12 10:50 ` Alexander Graf
2014-12-12 10:52 ` Alexander Graf
2014-12-12 11:17 ` Amit Tomar
2014-12-12 21:10 ` Scott Wood
2014-12-13 5:02 ` Amit Tomar
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).