* [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: gregkh; +Cc: linux-tegra, Tuomas Tynkkynen, linux-kernel, linux-arm-kernel
Hi,
Here's two simple bugfixes for the Tegra memory controllers.
v2: Fix a dumb bug in the bit masking.
Tuomas Tynkkynen (2):
memory: tegra20-mc: Fix hang in IRQ handler.
memory: tegra30-mc: Fix IRQ handler.
drivers/memory/tegra20-mc.c | 5 ++++-
drivers/memory/tegra30-mc.c | 9 ++++++---
2 files changed, 10 insertions(+), 4 deletions(-)
--
1.8.1.5
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: gregkh; +Cc: linux-tegra, linux-arm-kernel, linux-kernel, Tuomas Tynkkynen
Hi,
Here's two simple bugfixes for the Tegra memory controllers.
v2: Fix a dumb bug in the bit masking.
Tuomas Tynkkynen (2):
memory: tegra20-mc: Fix hang in IRQ handler.
memory: tegra30-mc: Fix IRQ handler.
drivers/memory/tegra20-mc.c | 5 ++++-
drivers/memory/tegra30-mc.c | 9 ++++++---
2 files changed, 10 insertions(+), 4 deletions(-)
--
1.8.1.5
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: linux-arm-kernel
Hi,
Here's two simple bugfixes for the Tegra memory controllers.
v2: Fix a dumb bug in the bit masking.
Tuomas Tynkkynen (2):
memory: tegra20-mc: Fix hang in IRQ handler.
memory: tegra30-mc: Fix IRQ handler.
drivers/memory/tegra20-mc.c | 5 ++++-
drivers/memory/tegra30-mc.c | 9 ++++++---
2 files changed, 10 insertions(+), 4 deletions(-)
--
1.8.1.5
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 1/2] memory: tegra20-mc: Fix hang in IRQ handler.
2013-06-11 10:11 ` Tuomas Tynkkynen
(?)
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
-1 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r
Cc: linux-tegra-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-kernel-u79uwXL29TY76Z2rM5mHXA, Tuomas Tynkkynen
In Tegra20 any memory controller interrupt would cause an
infinite loop in the IRQ handler.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
---
drivers/memory/tegra20-mc.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/memory/tegra20-mc.c b/drivers/memory/tegra20-mc.c
index 2ca5f28..0548eea 100644
--- a/drivers/memory/tegra20-mc.c
+++ b/drivers/memory/tegra20-mc.c
@@ -193,8 +193,11 @@ static irqreturn_t tegra20_mc_isr(int irq, void *data)
mask &= stat;
if (!mask)
return IRQ_NONE;
- while ((bit = ffs(mask)) != 0)
+ while ((bit = ffs(mask)) != 0) {
tegra20_mc_decode(mc, bit - 1);
+ mask &= ~BIT(bit - 1);
+ }
+
mc_writel(mc, stat, MC_INTSTATUS);
return IRQ_HANDLED;
}
--
1.8.1.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 1/2] memory: tegra20-mc: Fix hang in IRQ handler.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: gregkh; +Cc: linux-tegra, linux-arm-kernel, linux-kernel, Tuomas Tynkkynen
In Tegra20 any memory controller interrupt would cause an
infinite loop in the IRQ handler.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
---
drivers/memory/tegra20-mc.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/memory/tegra20-mc.c b/drivers/memory/tegra20-mc.c
index 2ca5f28..0548eea 100644
--- a/drivers/memory/tegra20-mc.c
+++ b/drivers/memory/tegra20-mc.c
@@ -193,8 +193,11 @@ static irqreturn_t tegra20_mc_isr(int irq, void *data)
mask &= stat;
if (!mask)
return IRQ_NONE;
- while ((bit = ffs(mask)) != 0)
+ while ((bit = ffs(mask)) != 0) {
tegra20_mc_decode(mc, bit - 1);
+ mask &= ~BIT(bit - 1);
+ }
+
mc_writel(mc, stat, MC_INTSTATUS);
return IRQ_HANDLED;
}
--
1.8.1.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 1/2] memory: tegra20-mc: Fix hang in IRQ handler.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: linux-arm-kernel
In Tegra20 any memory controller interrupt would cause an
infinite loop in the IRQ handler.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
---
drivers/memory/tegra20-mc.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/memory/tegra20-mc.c b/drivers/memory/tegra20-mc.c
index 2ca5f28..0548eea 100644
--- a/drivers/memory/tegra20-mc.c
+++ b/drivers/memory/tegra20-mc.c
@@ -193,8 +193,11 @@ static irqreturn_t tegra20_mc_isr(int irq, void *data)
mask &= stat;
if (!mask)
return IRQ_NONE;
- while ((bit = ffs(mask)) != 0)
+ while ((bit = ffs(mask)) != 0) {
tegra20_mc_decode(mc, bit - 1);
+ mask &= ~BIT(bit - 1);
+ }
+
mc_writel(mc, stat, MC_INTSTATUS);
return IRQ_HANDLED;
}
--
1.8.1.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 2/2] memory: tegra30-mc: Fix IRQ handler.
2013-06-11 10:11 ` Tuomas Tynkkynen
(?)
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
-1 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: gregkh; +Cc: linux-tegra, linux-arm-kernel, linux-kernel, Tuomas Tynkkynen
In Tegra30 any memory controller interrupt would cause an infinite loop in the
IRQ handler. Additionally, a garbage pointer was used to read the MC
status registers, which causes wrong values to be printed if a MC error
occurred.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
---
drivers/memory/tegra30-mc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/memory/tegra30-mc.c b/drivers/memory/tegra30-mc.c
index f4ae074..58d2979 100644
--- a/drivers/memory/tegra30-mc.c
+++ b/drivers/memory/tegra30-mc.c
@@ -218,7 +218,7 @@ static void tegra30_mc_decode(struct tegra30_mc *mc, int n)
return;
}
- err = readl(mc + MC_ERR_STATUS);
+ err = mc_readl(mc, MC_ERR_STATUS);
type = (err & MC_ERR_TYPE_MASK) >> MC_ERR_TYPE_SHIFT;
perm = (err & MC_ERR_INVALID_SMMU_PAGE_MASK) >>
@@ -235,7 +235,7 @@ static void tegra30_mc_decode(struct tegra30_mc *mc, int n)
if (cid < ARRAY_SIZE(tegra30_mc_client))
client = tegra30_mc_client[cid];
- addr = readl(mc + MC_ERR_ADR);
+ addr = mc_readl(mc, MC_ERR_ADR);
dev_err_ratelimited(mc->dev, "%s (0x%08x): 0x%08x %s (%s %s %s %s)\n",
mc_int_err[idx], err, addr, client,
@@ -313,8 +313,11 @@ static irqreturn_t tegra30_mc_isr(int irq, void *data)
mask &= stat;
if (!mask)
return IRQ_NONE;
- while ((bit = ffs(mask)) != 0)
+ while ((bit = ffs(mask)) != 0) {
tegra30_mc_decode(mc, bit - 1);
+ mask &= ~BIT(bit - 1);
+ }
+
mc_writel(mc, stat, MC_INTSTATUS);
return IRQ_HANDLED;
}
--
1.8.1.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 2/2] memory: tegra30-mc: Fix IRQ handler.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: gregkh; +Cc: linux-tegra, linux-arm-kernel, linux-kernel, Tuomas Tynkkynen
In Tegra30 any memory controller interrupt would cause an infinite loop in the
IRQ handler. Additionally, a garbage pointer was used to read the MC
status registers, which causes wrong values to be printed if a MC error
occurred.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
---
drivers/memory/tegra30-mc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/memory/tegra30-mc.c b/drivers/memory/tegra30-mc.c
index f4ae074..58d2979 100644
--- a/drivers/memory/tegra30-mc.c
+++ b/drivers/memory/tegra30-mc.c
@@ -218,7 +218,7 @@ static void tegra30_mc_decode(struct tegra30_mc *mc, int n)
return;
}
- err = readl(mc + MC_ERR_STATUS);
+ err = mc_readl(mc, MC_ERR_STATUS);
type = (err & MC_ERR_TYPE_MASK) >> MC_ERR_TYPE_SHIFT;
perm = (err & MC_ERR_INVALID_SMMU_PAGE_MASK) >>
@@ -235,7 +235,7 @@ static void tegra30_mc_decode(struct tegra30_mc *mc, int n)
if (cid < ARRAY_SIZE(tegra30_mc_client))
client = tegra30_mc_client[cid];
- addr = readl(mc + MC_ERR_ADR);
+ addr = mc_readl(mc, MC_ERR_ADR);
dev_err_ratelimited(mc->dev, "%s (0x%08x): 0x%08x %s (%s %s %s %s)\n",
mc_int_err[idx], err, addr, client,
@@ -313,8 +313,11 @@ static irqreturn_t tegra30_mc_isr(int irq, void *data)
mask &= stat;
if (!mask)
return IRQ_NONE;
- while ((bit = ffs(mask)) != 0)
+ while ((bit = ffs(mask)) != 0) {
tegra30_mc_decode(mc, bit - 1);
+ mask &= ~BIT(bit - 1);
+ }
+
mc_writel(mc, stat, MC_INTSTATUS);
return IRQ_HANDLED;
}
--
1.8.1.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 2/2] memory: tegra30-mc: Fix IRQ handler.
@ 2013-06-11 10:11 ` Tuomas Tynkkynen
0 siblings, 0 replies; 14+ messages in thread
From: Tuomas Tynkkynen @ 2013-06-11 10:11 UTC (permalink / raw)
To: linux-arm-kernel
In Tegra30 any memory controller interrupt would cause an infinite loop in the
IRQ handler. Additionally, a garbage pointer was used to read the MC
status registers, which causes wrong values to be printed if a MC error
occurred.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
---
drivers/memory/tegra30-mc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/memory/tegra30-mc.c b/drivers/memory/tegra30-mc.c
index f4ae074..58d2979 100644
--- a/drivers/memory/tegra30-mc.c
+++ b/drivers/memory/tegra30-mc.c
@@ -218,7 +218,7 @@ static void tegra30_mc_decode(struct tegra30_mc *mc, int n)
return;
}
- err = readl(mc + MC_ERR_STATUS);
+ err = mc_readl(mc, MC_ERR_STATUS);
type = (err & MC_ERR_TYPE_MASK) >> MC_ERR_TYPE_SHIFT;
perm = (err & MC_ERR_INVALID_SMMU_PAGE_MASK) >>
@@ -235,7 +235,7 @@ static void tegra30_mc_decode(struct tegra30_mc *mc, int n)
if (cid < ARRAY_SIZE(tegra30_mc_client))
client = tegra30_mc_client[cid];
- addr = readl(mc + MC_ERR_ADR);
+ addr = mc_readl(mc, MC_ERR_ADR);
dev_err_ratelimited(mc->dev, "%s (0x%08x): 0x%08x %s (%s %s %s %s)\n",
mc_int_err[idx], err, addr, client,
@@ -313,8 +313,11 @@ static irqreturn_t tegra30_mc_isr(int irq, void *data)
mask &= stat;
if (!mask)
return IRQ_NONE;
- while ((bit = ffs(mask)) != 0)
+ while ((bit = ffs(mask)) != 0) {
tegra30_mc_decode(mc, bit - 1);
+ mask &= ~BIT(bit - 1);
+ }
+
mc_writel(mc, stat, MC_INTSTATUS);
return IRQ_HANDLED;
}
--
1.8.1.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
2013-06-11 10:11 ` Tuomas Tynkkynen
@ 2013-06-11 10:33 ` Thierry Reding
-1 siblings, 0 replies; 14+ messages in thread
From: Thierry Reding @ 2013-06-11 10:33 UTC (permalink / raw)
To: Tuomas Tynkkynen; +Cc: gregkh, linux-tegra, linux-kernel, linux-arm-kernel
[-- Attachment #1: Type: text/plain, Size: 876 bytes --]
On Tue, Jun 11, 2013 at 01:11:17PM +0300, Tuomas Tynkkynen wrote:
> Hi,
>
> Here's two simple bugfixes for the Tegra memory controllers.
>
> v2: Fix a dumb bug in the bit masking.
>
> Tuomas Tynkkynen (2):
> memory: tegra20-mc: Fix hang in IRQ handler.
> memory: tegra30-mc: Fix IRQ handler.
>
> drivers/memory/tegra20-mc.c | 5 ++++-
> drivers/memory/tegra30-mc.c | 9 ++++++---
> 2 files changed, 10 insertions(+), 4 deletions(-)
Both patches:
Reviewed-by: Thierry Reding <thierry.reding@gmail.com>
On a side-note, the subject format looks a bit strange and my guess is
you had to manually edit it to insert "v2". git can do it for you when
you generate the patch series using:
git format-patch --subject-prefix='PATCH v2'
That'll also automatically add the v2 to all individual patches instead
of just the cover-letter.
Thierry
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
@ 2013-06-11 10:33 ` Thierry Reding
0 siblings, 0 replies; 14+ messages in thread
From: Thierry Reding @ 2013-06-11 10:33 UTC (permalink / raw)
To: linux-arm-kernel
On Tue, Jun 11, 2013 at 01:11:17PM +0300, Tuomas Tynkkynen wrote:
> Hi,
>
> Here's two simple bugfixes for the Tegra memory controllers.
>
> v2: Fix a dumb bug in the bit masking.
>
> Tuomas Tynkkynen (2):
> memory: tegra20-mc: Fix hang in IRQ handler.
> memory: tegra30-mc: Fix IRQ handler.
>
> drivers/memory/tegra20-mc.c | 5 ++++-
> drivers/memory/tegra30-mc.c | 9 ++++++---
> 2 files changed, 10 insertions(+), 4 deletions(-)
Both patches:
Reviewed-by: Thierry Reding <thierry.reding@gmail.com>
On a side-note, the subject format looks a bit strange and my guess is
you had to manually edit it to insert "v2". git can do it for you when
you generate the patch series using:
git format-patch --subject-prefix='PATCH v2'
That'll also automatically add the v2 to all individual patches instead
of just the cover-letter.
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130611/82711ac0/attachment.sig>
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
2013-06-11 10:11 ` Tuomas Tynkkynen
(?)
@ 2013-06-11 16:10 ` Stephen Warren
-1 siblings, 0 replies; 14+ messages in thread
From: Stephen Warren @ 2013-06-11 16:10 UTC (permalink / raw)
To: Tuomas Tynkkynen
Cc: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r,
linux-tegra-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r
On 06/11/2013 04:11 AM, Tuomas Tynkkynen wrote:
> Hi,
>
> Here's two simple bugfixes for the Tegra memory controllers.
>
> v2: Fix a dumb bug in the bit masking.
The series,
Reviewed-by: Stephen Warren <swarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
@ 2013-06-11 16:10 ` Stephen Warren
0 siblings, 0 replies; 14+ messages in thread
From: Stephen Warren @ 2013-06-11 16:10 UTC (permalink / raw)
To: Tuomas Tynkkynen; +Cc: gregkh, linux-tegra, linux-kernel, linux-arm-kernel
On 06/11/2013 04:11 AM, Tuomas Tynkkynen wrote:
> Hi,
>
> Here's two simple bugfixes for the Tegra memory controllers.
>
> v2: Fix a dumb bug in the bit masking.
The series,
Reviewed-by: Stephen Warren <swarren@nvidia.com>
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 0/2 v2] Bugfixes for Tegra memory controllers.
@ 2013-06-11 16:10 ` Stephen Warren
0 siblings, 0 replies; 14+ messages in thread
From: Stephen Warren @ 2013-06-11 16:10 UTC (permalink / raw)
To: linux-arm-kernel
On 06/11/2013 04:11 AM, Tuomas Tynkkynen wrote:
> Hi,
>
> Here's two simple bugfixes for the Tegra memory controllers.
>
> v2: Fix a dumb bug in the bit masking.
The series,
Reviewed-by: Stephen Warren <swarren@nvidia.com>
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2013-06-11 16:10 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-11 10:11 [PATCH 0/2 v2] Bugfixes for Tegra memory controllers Tuomas Tynkkynen
2013-06-11 10:11 ` Tuomas Tynkkynen
2013-06-11 10:11 ` Tuomas Tynkkynen
[not found] ` <1370945479-2917-1-git-send-email-ttynkkynen-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2013-06-11 10:11 ` [PATCH 1/2] memory: tegra20-mc: Fix hang in IRQ handler Tuomas Tynkkynen
2013-06-11 10:11 ` Tuomas Tynkkynen
2013-06-11 10:11 ` Tuomas Tynkkynen
2013-06-11 16:10 ` [PATCH 0/2 v2] Bugfixes for Tegra memory controllers Stephen Warren
2013-06-11 16:10 ` Stephen Warren
2013-06-11 16:10 ` Stephen Warren
2013-06-11 10:11 ` [PATCH 2/2] memory: tegra30-mc: Fix IRQ handler Tuomas Tynkkynen
2013-06-11 10:11 ` Tuomas Tynkkynen
2013-06-11 10:11 ` Tuomas Tynkkynen
2013-06-11 10:33 ` [PATCH 0/2 v2] Bugfixes for Tegra memory controllers Thierry Reding
2013-06-11 10:33 ` Thierry Reding
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.