Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 280443
b: refs/heads/master
c: 6099e41
h: refs/heads/master
i:
  280441: 4d294f0
  280439: 0910055
v: v3
  • Loading branch information
Arvind R authored and Jiri Kosina committed Oct 29, 2011
1 parent 647224f commit 33da25f
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 800100afc7a01ed581702bfaa6014f646e6eff5d
refs/heads/master: 6099e419ae7e1dd44c808693bd1905d22a6db15f
30 changes: 19 additions & 11 deletions trunk/drivers/edac/i82975x_edac.c
Original file line number Diff line number Diff line change
Expand Up @@ -277,11 +277,9 @@ static void i82975x_get_error_info(struct mem_ctl_info *mci,
static int i82975x_process_error_info(struct mem_ctl_info *mci,
struct i82975x_error_info *info, int handle_errors)
{
int row, multi_chan, chan;
int row, chan;
unsigned long offst, page;

multi_chan = mci->csrows[0].nr_channels - 1;

if (!(info->errsts2 & 0x0003))
return 0;

Expand All @@ -294,20 +292,30 @@ static int i82975x_process_error_info(struct mem_ctl_info *mci,
}

page = (unsigned long) info->eap;
if (info->xeap & 1)
page |= 0x100000000ul;
chan = page & 1;
page >>= 1;
offst = page & ((1 << PAGE_SHIFT) - 1);
page >>= PAGE_SHIFT;
if (info->xeap & 1)
page |= 0x80000000;
page >>= (PAGE_SHIFT - 1);
row = edac_mc_find_csrow_by_page(mci, page);

if (row == -1) {
i82975x_mc_printk(mci, KERN_ERR, "error processing EAP:\n"
"\tXEAP=%u\n"
"\t EAP=0x%08x\n"
"\tPAGE=0x%08x\n",
(info->xeap & 1) ? 1 : 0, info->eap, (unsigned int) page);
return 0;
}
chan = (mci->csrows[row].nr_channels == 1) ? 0 : info->eap & 1;
offst = info->eap
& ((1 << PAGE_SHIFT) -
(1 << mci->csrows[row].grain));

if (info->errsts & 0x0002)
edac_mc_handle_ue(mci, page, offst , row, "i82975x UE");
else
edac_mc_handle_ce(mci, page, offst, info->derrsyn, row,
multi_chan ? chan : 0,
"i82975x CE");
chan, "i82975x CE");

return 1;
}
Expand Down Expand Up @@ -410,7 +418,7 @@ static void i82975x_init_csrows(struct mem_ctl_info *mci,
csrow->last_page = cumul_size - 1;
csrow->nr_pages = cumul_size - last_cumul_size;
last_cumul_size = cumul_size;
csrow->grain = 1 << 6; /* I82975X_EAP has 64B resolution */
csrow->grain = 1 << 7; /* 128Byte cache-line resolution */
csrow->mtype = MEM_DDR2; /* I82975x supports only DDR2 */
csrow->dtype = i82975x_dram_type(mch_window, index);
csrow->edac_mode = EDAC_SECDED; /* only supported */
Expand Down

0 comments on commit 33da25f

Please sign in to comment.