linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] dma/amba-pl08x: check for terminal count status only
@ 2012-04-09 20:53 Linus Walleij
  2012-04-10  3:37 ` Viresh Kumar
  0 siblings, 1 reply; 2+ messages in thread
From: Linus Walleij @ 2012-04-09 20:53 UTC (permalink / raw)
  To: linux-arm-kernel

For some reason I can't figure out we're reading the PL080_INT_STATUS
register instead of PL080_TC_STATUS when checking for the terminal
count. The PL080_INT_STATUS is a logical OR between the error and
terminal count status register and may not report what we want it
to, especially if there is an error and a terminal count at the same
time and the former is not lowered in time for the check in the TC
register. Make sure we read what we're actually interested in.

Cc: Russell King <linux@arm.linux.org.uk>
Cc: Viresh Kumar <viresh.kumar@st.com>
Cc: Alim Akhtar <alim.akhtar@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 drivers/dma/amba-pl08x.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c
index c301a8e..08589c6 100644
--- a/drivers/dma/amba-pl08x.c
+++ b/drivers/dma/amba-pl08x.c
@@ -1615,7 +1615,7 @@ static irqreturn_t pl08x_irq(int irq, void *dev)
 			__func__, err);
 		writel(err, pl08x->base + PL080_ERR_CLEAR);
 	}
-	tc = readl(pl08x->base + PL080_INT_STATUS);
+	tc = readl(pl08x->base + PL080_TC_STATUS);
 	if (tc)
 		writel(tc, pl08x->base + PL080_TC_CLEAR);
 
-- 
1.7.7.6

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

* [PATCH 1/2] dma/amba-pl08x: check for terminal count status only
  2012-04-09 20:53 [PATCH 1/2] dma/amba-pl08x: check for terminal count status only Linus Walleij
@ 2012-04-10  3:37 ` Viresh Kumar
  0 siblings, 0 replies; 2+ messages in thread
From: Viresh Kumar @ 2012-04-10  3:37 UTC (permalink / raw)
  To: linux-arm-kernel

On 4/10/2012 2:23 AM, Linus Walleij wrote:
> For some reason I can't figure out we're reading the PL080_INT_STATUS
> register instead of PL080_TC_STATUS when checking for the terminal
> count. The PL080_INT_STATUS is a logical OR between the error and
> terminal count status register and may not report what we want it
> to, especially if there is an error and a terminal count at the same
> time and the former is not lowered in time for the check in the TC
> register. Make sure we read what we're actually interested in.
> 
> Cc: Russell King <linux@arm.linux.org.uk>
> Cc: Viresh Kumar <viresh.kumar@st.com>
> Cc: Alim Akhtar <alim.akhtar@gmail.com>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
>  drivers/dma/amba-pl08x.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c
> index c301a8e..08589c6 100644
> --- a/drivers/dma/amba-pl08x.c
> +++ b/drivers/dma/amba-pl08x.c
> @@ -1615,7 +1615,7 @@ static irqreturn_t pl08x_irq(int irq, void *dev)
>  			__func__, err);
>  		writel(err, pl08x->base + PL080_ERR_CLEAR);
>  	}
> -	tc = readl(pl08x->base + PL080_INT_STATUS);
> +	tc = readl(pl08x->base + PL080_TC_STATUS);
>  	if (tc)
>  		writel(tc, pl08x->base + PL080_TC_CLEAR);
>  

Acked-by: Viresh Kumar <viresh.kumar@st.com>

-- 
viresh

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

end of thread, other threads:[~2012-04-10  3:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-09 20:53 [PATCH 1/2] dma/amba-pl08x: check for terminal count status only Linus Walleij
2012-04-10  3:37 ` Viresh Kumar

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