Commit 84db003f authored by Mike Chan's avatar Mike Chan Committed by Linus Torvalds

[PATCH] EDAC: Fix in e752x mc driver

This fix/change returns the offset into the page for the ce/ue error, instead
of just 0.  The e752x dram controller reads 34:6 of the linear address with
the error.
Signed-off-by: default avatarMike Chan <mikechan@google.com>
Signed-off-by: default avatardoug thompson <norsk5@xmission.com>
Acked-by: default avatarAlan Cox <alan@redhat.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 9962fd01
...@@ -285,8 +285,9 @@ static void do_process_ce(struct mem_ctl_info *mci, u16 error_one, ...@@ -285,8 +285,9 @@ static void do_process_ce(struct mem_ctl_info *mci, u16 error_one,
if (!pvt->map_type) if (!pvt->map_type)
row = 7 - row; row = 7 - row;
edac_mc_handle_ce(mci, page, 0, sec1_syndrome, row, channel, /* e752x mc reads 34:6 of the DRAM linear address */
"e752x CE"); edac_mc_handle_ce(mci, page, offset_in_page(sec1_add << 4),
sec1_syndrome, row, channel, "e752x CE");
} }
static inline void process_ce(struct mem_ctl_info *mci, u16 error_one, static inline void process_ce(struct mem_ctl_info *mci, u16 error_one,
...@@ -319,8 +320,10 @@ static void do_process_ue(struct mem_ctl_info *mci, u16 error_one, ...@@ -319,8 +320,10 @@ static void do_process_ue(struct mem_ctl_info *mci, u16 error_one,
((block_page >> 1) & 3) : ((block_page >> 1) & 3) :
edac_mc_find_csrow_by_page(mci, block_page); edac_mc_find_csrow_by_page(mci, block_page);
edac_mc_handle_ue(mci, block_page, 0, row, /* e752x mc reads 34:6 of the DRAM linear address */
"e752x UE from Read"); edac_mc_handle_ue(mci, block_page,
offset_in_page(error_2b << 4),
row, "e752x UE from Read");
} }
if (error_one & 0x0404) { if (error_one & 0x0404) {
error_2b = scrb_add; error_2b = scrb_add;
...@@ -333,8 +336,10 @@ static void do_process_ue(struct mem_ctl_info *mci, u16 error_one, ...@@ -333,8 +336,10 @@ static void do_process_ue(struct mem_ctl_info *mci, u16 error_one,
((block_page >> 1) & 3) : ((block_page >> 1) & 3) :
edac_mc_find_csrow_by_page(mci, block_page); edac_mc_find_csrow_by_page(mci, block_page);
edac_mc_handle_ue(mci, block_page, 0, row, /* e752x mc reads 34:6 of the DRAM linear address */
"e752x UE from Scruber"); edac_mc_handle_ue(mci, block_page,
offset_in_page(error_2b << 4),
row, "e752x UE from Scruber");
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment