All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
@ 2011-04-27 14:03 Laurent Pinchart
  2011-04-29 10:03 ` Laurent Pinchart
  0 siblings, 1 reply; 7+ messages in thread
From: Laurent Pinchart @ 2011-04-27 14:03 UTC (permalink / raw)
  To: linux-omap; +Cc: David Cohen, Hiroshi DOYU, Tony Lindgren

The iommu shares an interrupt line with the OMAP3 ISP. The iommu
interrupt handler must check the fault status and return IRQ_HANDLED
when no fault occured.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 arch/arm/plat-omap/iommu.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

The OMAP3 ISP IOMMU got broken in 2.6.39-rc1 by

commit d594f1f31afe13edd8c02f3854a65cc58cfb3b74
Author: David Cohen <dacohen@gmail.com>
Date:   Wed Feb 16 19:35:51 2011 +0000

    omap: IOMMU: add support to callback during fault handling
    
    Add support to register an isr for IOMMU fault situations and adapt it
    to allow such (*isr)() to be used as fault callback. Drivers using IOMMU
    module might want to be informed when errors happen in order to debug it
    or react.
    
    Signed-off-by: David Cohen <dacohen@gmail.com>
    Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
    Signed-off-by: Tony Lindgren <tony@atomide.com>

This patch fixes it and should be pushed to mainline in 2.6.39. The OMAP3 ISP
driver, new in 2.6.39, would otherwise be totally broken until 2.6.40.

diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
index 8a51fd5..34fc31e 100644
--- a/arch/arm/plat-omap/iommu.c
+++ b/arch/arm/plat-omap/iommu.c
@@ -793,6 +793,8 @@ static irqreturn_t iommu_fault_handler(int irq, void *data)
 	clk_enable(obj->clk);
 	errs = iommu_report_fault(obj, &da);
 	clk_disable(obj->clk);
+	if (errs == 0)
+		return IRQ_HANDLED;
 
 	/* Fault callback or TLB/PTE Dynamic loading */
 	if (obj->isr && !obj->isr(obj, da, errs, obj->isr_priv))
-- 
Regards,

Laurent Pinchart


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

* Re: [PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
  2011-04-27 14:03 [PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured Laurent Pinchart
@ 2011-04-29 10:03 ` Laurent Pinchart
  2011-05-10 12:39   ` [URGENT - PATCH " Laurent Pinchart
  0 siblings, 1 reply; 7+ messages in thread
From: Laurent Pinchart @ 2011-04-29 10:03 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: linux-omap, David Cohen, Hiroshi DOYU

Hi Tony,

On Wednesday 27 April 2011 16:03:02 Laurent Pinchart wrote:
> The iommu shares an interrupt line with the OMAP3 ISP. The iommu
> interrupt handler must check the fault status and return IRQ_HANDLED
> when no fault occured.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

Could you please pick this one up for 2.6.39 ? As far as I know David is on 
holidays so he might not be able to review the patch before the 2.6.39 
release.

> ---
>  arch/arm/plat-omap/iommu.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> The OMAP3 ISP IOMMU got broken in 2.6.39-rc1 by
> 
> commit d594f1f31afe13edd8c02f3854a65cc58cfb3b74
> Author: David Cohen <dacohen@gmail.com>
> Date:   Wed Feb 16 19:35:51 2011 +0000
> 
>     omap: IOMMU: add support to callback during fault handling
> 
>     Add support to register an isr for IOMMU fault situations and adapt it
>     to allow such (*isr)() to be used as fault callback. Drivers using
> IOMMU module might want to be informed when errors happen in order to
> debug it or react.
> 
>     Signed-off-by: David Cohen <dacohen@gmail.com>
>     Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
>     Signed-off-by: Tony Lindgren <tony@atomide.com>
> 
> This patch fixes it and should be pushed to mainline in 2.6.39. The OMAP3
> ISP driver, new in 2.6.39, would otherwise be totally broken until 2.6.40.
> 
> diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
> index 8a51fd5..34fc31e 100644
> --- a/arch/arm/plat-omap/iommu.c
> +++ b/arch/arm/plat-omap/iommu.c
> @@ -793,6 +793,8 @@ static irqreturn_t iommu_fault_handler(int irq, void
> *data) clk_enable(obj->clk);
>  	errs = iommu_report_fault(obj, &da);
>  	clk_disable(obj->clk);
> +	if (errs == 0)
> +		return IRQ_HANDLED;
> 
>  	/* Fault callback or TLB/PTE Dynamic loading */
>  	if (obj->isr && !obj->isr(obj, da, errs, obj->isr_priv))

-- 
Regards,

Laurent Pinchart

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

* Re: [URGENT - PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
  2011-04-29 10:03 ` Laurent Pinchart
@ 2011-05-10 12:39   ` Laurent Pinchart
  2011-05-10 13:19     ` Tony Lindgren
  2011-05-10 13:32     ` [URGENT - PATCH " Hiroshi DOYU
  0 siblings, 2 replies; 7+ messages in thread
From: Laurent Pinchart @ 2011-05-10 12:39 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: linux-omap, David Cohen, Hiroshi DOYU, linux-kernel

Hi Tony,

On Friday 29 April 2011 12:03:10 Laurent Pinchart wrote:
> Hi Tony,
> 
> On Wednesday 27 April 2011 16:03:02 Laurent Pinchart wrote:
> > The iommu shares an interrupt line with the OMAP3 ISP. The iommu
> > interrupt handler must check the fault status and return IRQ_HANDLED
> > when no fault occured.
> > 
> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> 
> Could you please pick this one up for 2.6.39 ? As far as I know David is on
> holidays so he might not be able to review the patch before the 2.6.39
> release.

Ping. Please.

> > ---
> > 
> >  arch/arm/plat-omap/iommu.c |    2 ++
> >  1 files changed, 2 insertions(+), 0 deletions(-)
> > 
> > The OMAP3 ISP IOMMU got broken in 2.6.39-rc1 by
> > 
> > commit d594f1f31afe13edd8c02f3854a65cc58cfb3b74
> > Author: David Cohen <dacohen@gmail.com>
> > Date:   Wed Feb 16 19:35:51 2011 +0000
> > 
> >     omap: IOMMU: add support to callback during fault handling
> >     
> >     Add support to register an isr for IOMMU fault situations and adapt
> >     it to allow such (*isr)() to be used as fault callback. Drivers
> >     using
> > 
> > IOMMU module might want to be informed when errors happen in order to
> > debug it or react.
> > 
> >     Signed-off-by: David Cohen <dacohen@gmail.com>
> >     Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
> >     Signed-off-by: Tony Lindgren <tony@atomide.com>
> > 
> > This patch fixes it and should be pushed to mainline in 2.6.39. The OMAP3
> > ISP driver, new in 2.6.39, would otherwise be totally broken until
> > 2.6.40.
> > 
> > diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
> > index 8a51fd5..34fc31e 100644
> > --- a/arch/arm/plat-omap/iommu.c
> > +++ b/arch/arm/plat-omap/iommu.c
> > @@ -793,6 +793,8 @@ static irqreturn_t iommu_fault_handler(int irq, void
> > *data) clk_enable(obj->clk);
> > 
> >  	errs = iommu_report_fault(obj, &da);
> >  	clk_disable(obj->clk);
> > 
> > +	if (errs == 0)
> > +		return IRQ_HANDLED;
> > 
> >  	/* Fault callback or TLB/PTE Dynamic loading */
> >  	if (obj->isr && !obj->isr(obj, da, errs, obj->isr_priv))

-- 
Regards,

Laurent Pinchart

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

* Re: [URGENT - PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
  2011-05-10 12:39   ` [URGENT - PATCH " Laurent Pinchart
@ 2011-05-10 13:19     ` Tony Lindgren
  2011-05-10 14:56         ` Laurent Pinchart
  2011-05-10 13:32     ` [URGENT - PATCH " Hiroshi DOYU
  1 sibling, 1 reply; 7+ messages in thread
From: Tony Lindgren @ 2011-05-10 13:19 UTC (permalink / raw)
  To: Laurent Pinchart; +Cc: linux-omap, David Cohen, Hiroshi DOYU, linux-kernel

* Laurent Pinchart <laurent.pinchart@ideasonboard.com> [110510 15:35]:
> Hi Tony,
> 
> On Friday 29 April 2011 12:03:10 Laurent Pinchart wrote:
> > Hi Tony,
> > 
> > On Wednesday 27 April 2011 16:03:02 Laurent Pinchart wrote:
> > > The iommu shares an interrupt line with the OMAP3 ISP. The iommu
> > > interrupt handler must check the fault status and return IRQ_HANDLED
> > > when no fault occured.

Can you please update the description to say something like:

Commit d594f1f31afe13edd8c02f3854a65cc58cfb3b74 (Title of the commit
here) broke XYZ and because of this so and so happens.

Then please repost the patch with linux-arm-kernel mailing list Cc'd.
 
> > > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > 
> > Could you please pick this one up for 2.6.39 ? As far as I know David is on
> > holidays so he might not be able to review the patch before the 2.6.39
> > release.
> 
> Ping. Please.

Well at least we now have something close to an ack from Hiroshi..
We really want to have acks for fixes like this, otherwise I don't
feel comfortable to rush something like this in.

Regards,

Tony

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

* Re: [URGENT - PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
  2011-05-10 12:39   ` [URGENT - PATCH " Laurent Pinchart
  2011-05-10 13:19     ` Tony Lindgren
@ 2011-05-10 13:32     ` Hiroshi DOYU
  1 sibling, 0 replies; 7+ messages in thread
From: Hiroshi DOYU @ 2011-05-10 13:32 UTC (permalink / raw)
  To: laurent.pinchart; +Cc: tony, linux-omap, dacohen, linux-kernel

From: ext Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Subject: Re: [URGENT - PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
Date: Tue, 10 May 2011 14:39:56 +0200

> Hi Tony,
> 
> On Friday 29 April 2011 12:03:10 Laurent Pinchart wrote:
>> Hi Tony,
>> 
>> On Wednesday 27 April 2011 16:03:02 Laurent Pinchart wrote:
>> > The iommu shares an interrupt line with the OMAP3 ISP. The iommu
>> > interrupt handler must check the fault status and return IRQ_HANDLED
>> > when no fault occured.
>> > 
>> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>> 
>> Could you please pick this one up for 2.6.39 ? As far as I know David is on
>> holidays so he might not be able to review the patch before the 2.6.39
>> release.
> 
> Ping. Please.

Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>

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

* [PATCH v2 FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
  2011-05-10 13:19     ` Tony Lindgren
@ 2011-05-10 14:56         ` Laurent Pinchart
  0 siblings, 0 replies; 7+ messages in thread
From: Laurent Pinchart @ 2011-05-10 14:56 UTC (permalink / raw)
  To: tony; +Cc: linux-omap, linux-arm-kernel, linux-kernel, dacohen, Hiroshi.DOYU

Commit d594f1f31afe13edd8c02f3854a65cc58cfb3b74 (omap: IOMMU: add
support to callback during fault handling) broke interrupt line sharing
between the OMAP3 ISP and its IOMMU. Because of this, every interrupt
generated by the OMAP3 ISP is handled by the IOMMU driver instead of
being passed to the OMAP3 ISP driver.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
---
 arch/arm/plat-omap/iommu.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
index 8a51fd5..34fc31e 100644
--- a/arch/arm/plat-omap/iommu.c
+++ b/arch/arm/plat-omap/iommu.c
@@ -793,6 +793,8 @@ static irqreturn_t iommu_fault_handler(int irq, void *data)
 	clk_enable(obj->clk);
 	errs = iommu_report_fault(obj, &da);
 	clk_disable(obj->clk);
+	if (errs == 0)
+		return IRQ_HANDLED;
 
 	/* Fault callback or TLB/PTE Dynamic loading */
 	if (obj->isr && !obj->isr(obj, da, errs, obj->isr_priv))
-- 
Regards,

Laurent Pinchart

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

* [PATCH v2 FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured
@ 2011-05-10 14:56         ` Laurent Pinchart
  0 siblings, 0 replies; 7+ messages in thread
From: Laurent Pinchart @ 2011-05-10 14:56 UTC (permalink / raw)
  To: linux-arm-kernel

Commit d594f1f31afe13edd8c02f3854a65cc58cfb3b74 (omap: IOMMU: add
support to callback during fault handling) broke interrupt line sharing
between the OMAP3 ISP and its IOMMU. Because of this, every interrupt
generated by the OMAP3 ISP is handled by the IOMMU driver instead of
being passed to the OMAP3 ISP driver.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
---
 arch/arm/plat-omap/iommu.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
index 8a51fd5..34fc31e 100644
--- a/arch/arm/plat-omap/iommu.c
+++ b/arch/arm/plat-omap/iommu.c
@@ -793,6 +793,8 @@ static irqreturn_t iommu_fault_handler(int irq, void *data)
 	clk_enable(obj->clk);
 	errs = iommu_report_fault(obj, &da);
 	clk_disable(obj->clk);
+	if (errs == 0)
+		return IRQ_HANDLED;
 
 	/* Fault callback or TLB/PTE Dynamic loading */
 	if (obj->isr && !obj->isr(obj, da, errs, obj->isr_priv))
-- 
Regards,

Laurent Pinchart

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

end of thread, other threads:[~2011-05-10 14:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-27 14:03 [PATCH FOR 2.6.39] omap: iommu: Return IRQ_HANDLED in fault handler when no fault occured Laurent Pinchart
2011-04-29 10:03 ` Laurent Pinchart
2011-05-10 12:39   ` [URGENT - PATCH " Laurent Pinchart
2011-05-10 13:19     ` Tony Lindgren
2011-05-10 14:56       ` [PATCH v2 " Laurent Pinchart
2011-05-10 14:56         ` Laurent Pinchart
2011-05-10 13:32     ` [URGENT - PATCH " Hiroshi DOYU

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.