Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[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: Mike Chan <mikechan@google.com>
Signed-off-by: doug thompson <norsk5@xmission.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Mike Chan and committed by
Linus Torvalds
84db003f 9962fd01

+11 -6
+11 -6
drivers/edac/e752x_edac.c
··· 285 285 if (!pvt->map_type) 286 286 row = 7 - row; 287 287 288 - edac_mc_handle_ce(mci, page, 0, sec1_syndrome, row, channel, 289 - "e752x CE"); 288 + /* e752x mc reads 34:6 of the DRAM linear address */ 289 + edac_mc_handle_ce(mci, page, offset_in_page(sec1_add << 4), 290 + sec1_syndrome, row, channel, "e752x CE"); 290 291 } 291 292 292 293 static inline void process_ce(struct mem_ctl_info *mci, u16 error_one, ··· 320 319 ((block_page >> 1) & 3) : 321 320 edac_mc_find_csrow_by_page(mci, block_page); 322 321 323 - edac_mc_handle_ue(mci, block_page, 0, row, 324 - "e752x UE from Read"); 322 + /* e752x mc reads 34:6 of the DRAM linear address */ 323 + edac_mc_handle_ue(mci, block_page, 324 + offset_in_page(error_2b << 4), 325 + row, "e752x UE from Read"); 325 326 } 326 327 if (error_one & 0x0404) { 327 328 error_2b = scrb_add; ··· 336 333 ((block_page >> 1) & 3) : 337 334 edac_mc_find_csrow_by_page(mci, block_page); 338 335 339 - edac_mc_handle_ue(mci, block_page, 0, row, 340 - "e752x UE from Scruber"); 336 + /* e752x mc reads 34:6 of the DRAM linear address */ 337 + edac_mc_handle_ue(mci, block_page, 338 + offset_in_page(error_2b << 4), 339 + row, "e752x UE from Scruber"); 341 340 } 342 341 } 343 342