Commit 53d4d779 authored by Yang Wang's avatar Yang Wang Committed by Alex Deucher

drm/amdgpu: fix find ras error node error

the origin function might return the wrong node.

Fixes: 5b1270be ("drm/amdgpu: add ras_err_info to identify RAS error source")
Signed-off-by: default avatarYang Wang <kevinyang.wang@amd.com>
Reviewed-by: default avatarHawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent bf795156
...@@ -3529,10 +3529,9 @@ static struct ras_err_node *amdgpu_ras_error_find_node_by_id(struct ras_err_data ...@@ -3529,10 +3529,9 @@ static struct ras_err_node *amdgpu_ras_error_find_node_by_id(struct ras_err_data
for_each_ras_error(err_node, err_data) { for_each_ras_error(err_node, err_data) {
ref_id = &err_node->err_info.mcm_info; ref_id = &err_node->err_info.mcm_info;
if ((mcm_info->socket_id >= 0 && mcm_info->socket_id != ref_id->socket_id) ||
(mcm_info->die_id >= 0 && mcm_info->die_id != ref_id->die_id))
continue;
if (mcm_info->socket_id == ref_id->socket_id &&
mcm_info->die_id == ref_id->die_id)
return err_node; return err_node;
} }
......
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