* [PATCH] Correct offset_in_page mask bits in function edac_mc_handle_ce.
@ 2011-07-14 2:01 Shaohui Xie
2011-07-14 21:50 ` Andrew Morton
0 siblings, 1 reply; 3+ messages in thread
From: Shaohui Xie @ 2011-07-14 2:01 UTC (permalink / raw)
To: linuxppc-dev
Cc: kumar.gala, Kai.Jiang, djiang, ptyser, dougthompson, scottwood,
akpm
From: Kai.Jiang <Kai.Jiang@freescale.com>
Parameter offset_in_page in function edac_mc_handle_ce should be masked
the higher bits above the page size, not the lower bits. The original input
sometimes causes crash.
Signed-off-by: Kai.Jiang <Kai.Jiang@freescale.com>
---
drivers/edac/mpc85xx_edac.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/edac/mpc85xx_edac.c b/drivers/edac/mpc85xx_edac.c
index 38ab8e2..b048a5f 100644
--- a/drivers/edac/mpc85xx_edac.c
+++ b/drivers/edac/mpc85xx_edac.c
@@ -854,11 +854,11 @@ static void mpc85xx_mc_check(struct mem_ctl_info *mci)
mpc85xx_mc_printk(mci, KERN_ERR, "PFN out of range!\n");
if (err_detect & DDR_EDE_SBE)
- edac_mc_handle_ce(mci, pfn, err_addr & PAGE_MASK,
+ edac_mc_handle_ce(mci, pfn, err_addr & ~PAGE_MASK,
syndrome, row_index, 0, mci->ctl_name);
if (err_detect & DDR_EDE_MBE)
- edac_mc_handle_ue(mci, pfn, err_addr & PAGE_MASK,
+ edac_mc_handle_ue(mci, pfn, err_addr & ~PAGE_MASK,
row_index, mci->ctl_name);
out_be32(pdata->mc_vbase + MPC85XX_MC_ERR_DETECT, err_detect);
--
1.6.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Correct offset_in_page mask bits in function edac_mc_handle_ce.
2011-07-14 2:01 [PATCH] Correct offset_in_page mask bits in function edac_mc_handle_ce Shaohui Xie
@ 2011-07-14 21:50 ` Andrew Morton
2011-07-15 6:21 ` Xie Shaohui-B21989
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2011-07-14 21:50 UTC (permalink / raw)
To: Shaohui Xie
Cc: kumar.gala, Kai.Jiang, djiang, ptyser, dougthompson, scottwood,
linuxppc-dev
On Thu, 14 Jul 2011 10:01:42 +0800
Shaohui Xie <Shaohui.Xie@freescale.com> wrote:
> From: Kai.Jiang <Kai.Jiang@freescale.com>
>
> Parameter offset_in_page in function edac_mc_handle_ce should be masked
> the higher bits above the page size, not the lower bits. The original input
> sometimes causes crash.
>
> Signed-off-by: Kai.Jiang <Kai.Jiang@freescale.com>
> ---
> drivers/edac/mpc85xx_edac.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/edac/mpc85xx_edac.c b/drivers/edac/mpc85xx_edac.c
> index 38ab8e2..b048a5f 100644
> --- a/drivers/edac/mpc85xx_edac.c
> +++ b/drivers/edac/mpc85xx_edac.c
> @@ -854,11 +854,11 @@ static void mpc85xx_mc_check(struct mem_ctl_info *mci)
> mpc85xx_mc_printk(mci, KERN_ERR, "PFN out of range!\n");
>
> if (err_detect & DDR_EDE_SBE)
> - edac_mc_handle_ce(mci, pfn, err_addr & PAGE_MASK,
> + edac_mc_handle_ce(mci, pfn, err_addr & ~PAGE_MASK,
> syndrome, row_index, 0, mci->ctl_name);
>
> if (err_detect & DDR_EDE_MBE)
> - edac_mc_handle_ue(mci, pfn, err_addr & PAGE_MASK,
> + edac_mc_handle_ue(mci, pfn, err_addr & ~PAGE_MASK,
> row_index, mci->ctl_name);
>
> out_be32(pdata->mc_vbase + MPC85XX_MC_ERR_DETECT, err_detect);
The patch should have had your Signed-off-by:, as described in
Documentation/SubmittingPatches. I added your s-o-b to my copy -
please ack this.
>From the description it appears to me that this fix should be
backported into 2.6.39.x and earlier. Do you agree?
The way to indicate this intention is to add "Cc: <stable@kernel.org>"
to the changelog. I added that tag to my copy of this patch.
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [PATCH] Correct offset_in_page mask bits in function edac_mc_handle_ce.
2011-07-14 21:50 ` Andrew Morton
@ 2011-07-15 6:21 ` Xie Shaohui-B21989
0 siblings, 0 replies; 3+ messages in thread
From: Xie Shaohui-B21989 @ 2011-07-15 6:21 UTC (permalink / raw)
To: Andrew Morton
Cc: Wood Scott-B07421, djiang@mvista.com, ptyser@xes-inc.com,
Jiang Kai-B18973, dougthompson@xmission.com, Gala Kumar-B11780,
linuxppc-dev@lists.ozlabs.org
>-----Original Message-----
>From: Andrew Morton [mailto:akpm@linux-foundation.org]
>Sent: Friday, July 15, 2011 5:51 AM
>To: Xie Shaohui-B21989
>Cc: linuxppc-dev@lists.ozlabs.org; Gala Kumar-B11780; Wood Scott-B07421;
>ptyser@xes-inc.com; djiang@mvista.com; dougthompson@xmission.com; Jiang
>Kai-B18973
>Subject: Re: [PATCH] Correct offset_in_page mask bits in function
>edac_mc_handle_ce.
>
>On Thu, 14 Jul 2011 10:01:42 +0800
>Shaohui Xie <Shaohui.Xie@freescale.com> wrote:
>
>> From: Kai.Jiang <Kai.Jiang@freescale.com>
>>
>> Parameter offset_in_page in function edac_mc_handle_ce should be
>> masked the higher bits above the page size, not the lower bits. The
>> original input sometimes causes crash.
>>
>> Signed-off-by: Kai.Jiang <Kai.Jiang@freescale.com>
>> ---
>> drivers/edac/mpc85xx_edac.c | 4 ++--
>> 1 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/edac/mpc85xx_edac.c b/drivers/edac/mpc85xx_edac.c
>> index 38ab8e2..b048a5f 100644
>> --- a/drivers/edac/mpc85xx_edac.c
>> +++ b/drivers/edac/mpc85xx_edac.c
>> @@ -854,11 +854,11 @@ static void mpc85xx_mc_check(struct mem_ctl_info
>*mci)
>> mpc85xx_mc_printk(mci, KERN_ERR, "PFN out of range!\n");
>>
>> if (err_detect & DDR_EDE_SBE)
>> - edac_mc_handle_ce(mci, pfn, err_addr & PAGE_MASK,
>> + edac_mc_handle_ce(mci, pfn, err_addr & ~PAGE_MASK,
>> syndrome, row_index, 0, mci->ctl_name);
>>
>> if (err_detect & DDR_EDE_MBE)
>> - edac_mc_handle_ue(mci, pfn, err_addr & PAGE_MASK,
>> + edac_mc_handle_ue(mci, pfn, err_addr & ~PAGE_MASK,
>> row_index, mci->ctl_name);
>>
>> out_be32(pdata->mc_vbase + MPC85XX_MC_ERR_DETECT, err_detect);
>
>The patch should have had your Signed-off-by:, as described in
>Documentation/SubmittingPatches. I added your s-o-b to my copy - please
>ack this.
[Xie Shaohui] OK, thank you.
>
>From the description it appears to me that this fix should be backported
>into 2.6.39.x and earlier. Do you agree?
[Xie Shaohui] Actually this patch was created based on 2.6.32, it can be ap=
plied=20
to 2.6.39 and 3.0 without any change.
>
>The way to indicate this intention is to add "Cc: <stable@kernel.org>"
>to the changelog. I added that tag to my copy of this patch.
[Xie Shaohui] OK, thank you.
Best Regards,=20
Shaohui Xie
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-07-15 6:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-14 2:01 [PATCH] Correct offset_in_page mask bits in function edac_mc_handle_ce Shaohui Xie
2011-07-14 21:50 ` Andrew Morton
2011-07-15 6:21 ` Xie Shaohui-B21989
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).