提交 4688c9b4 编写于 作者: Y Yazen Ghannam 提交者: Borislav Petkov

EDAC, amd64: Don't treat ECC disabled as failure

Having ECC disabled on a node doesn't necessarily mean that it's
disabled for the entire system. So let's return a non-failing code when
ECC is disabled on a node. This way we can skip initialization for the
node but still continue with the remaining nodes.

After probing all instances, make sure we have at least one MC device
allocated.

This issue is seen and fix tested on Fam15h and Fam17h MCM systems.
Signed-off-by: NYazen Ghannam <Yazen.Ghannam@amd.com>
Cc: linux-edac <linux-edac@vger.kernel.org>
Link: http://lkml.kernel.org/r/1485537863-2707-8-git-send-email-Yazen.Ghannam@amd.comSigned-off-by: NBorislav Petkov <bp@suse.de>
上级 d7fc9d77
...@@ -3336,7 +3336,7 @@ static int probe_one_instance(unsigned int nid) ...@@ -3336,7 +3336,7 @@ static int probe_one_instance(unsigned int nid)
ecc_stngs[nid] = s; ecc_stngs[nid] = s;
if (!ecc_enabled(F3, nid)) { if (!ecc_enabled(F3, nid)) {
ret = -ENODEV; ret = 0;
if (!ecc_enable_override) if (!ecc_enable_override)
goto err_enable; goto err_enable;
...@@ -3465,6 +3465,11 @@ static int __init amd64_edac_init(void) ...@@ -3465,6 +3465,11 @@ static int __init amd64_edac_init(void)
} }
} }
if (!edac_has_mcs()) {
err = -ENODEV;
goto err_pci;
}
/* register stuff with EDAC MCE */ /* register stuff with EDAC MCE */
if (report_gart_errors) if (report_gart_errors)
amd_report_gart_errors(true); amd_report_gart_errors(true);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册