amd64_edac: Fix syndrome calculation on K8
commit9c9e12e6e9980e37714f2f85287848d1c102def9
authorBorislav Petkov <borislav.petkov@amd.com>
Fri, 2 Jul 2010 15:02:43 +0000 (2 17:02 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 2 Aug 2010 17:26:36 +0000 (2 10:26 -0700)
treeac6d182368937b634bdfd16c5e989c389ca7c92c
parent3e45ee788963993dae419cc49f074f441d4c7d66
amd64_edac: Fix syndrome calculation on K8

commit 41c310447fe06bcedc22b75752c18b60e0b9521b upstream.

When calculating the DCT channel from the syndrome we need to know the
syndrome type (x4 vs x8). On F10h, this is read out from extended PCI
cfg space register F3x180 while on K8 we only support x4 syndromes and
don't have extended PCI config space anyway.

Make the code accessing F3x180 F10h only and fall back to x4 syndromes
on everything else.

Reported-by: Jeffrey Merkey <jeffmerkey@gmail.com>
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/edac/amd64_edac.c