Commit 38a8daca authored by Wenhui Fan's avatar Wenhui Fan
Browse files

EDAC/amd64: Don't use the ATL for Hygon model 4h~fh and 10h processors

hygon inclusion
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/IB0CWI


CVE: NA

---------------------------

Translate the normal address to system address is different for Hygon model
4h~fh and 10h processors.

The umc instance id is also differnt for Hygon model 6h processor.

Fixes: ef9aad1a ("EDAC/amd64: Use new AMD Address Translation Library")
Signed-off-by: default avatarWenhui Fan <fanwh@hygon.cn>
parent ebf321fb
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -3150,8 +3150,12 @@ static void decode_umc_error(int node_id, struct mce *m)

	pvt->ops->get_err_info(m, &err);

	if (hygon_f18h_m4h() && boot_cpu_data.x86_model == 0x6) {
	if (hygon_f18h_m4h() || boot_cpu_data.x86_model == 0x10) {
		if (boot_cpu_data.x86_model == 0x6)
			umc = err.channel << 1;
		else
			umc = err.channel;

		if (umc_normaddr_to_sysaddr(m->addr, pvt->mc_node_id, umc, &sys_addr)) {
			err.err_code = ERR_NORM_ADDR;
			goto log_error;