drm/amdgpu: Adjust the sequence to query ras error info
authorHawking Zhang <Hawking.Zhang@amd.com>
Mon, 20 Mar 2023 09:51:30 +0000 (17:51 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 9 Jun 2023 13:58:32 +0000 (09:58 -0400)
commit9b337b7d628a5e97b4dd72bb1d75f1716567b416
treea9d6954bb508148642b127e18937d66673c4da3e
parent35d54e21e002198c13647b6cd8c77586f683cf39
drm/amdgpu: Adjust the sequence to query ras error info

It turns out STATUS_VALID_FLAG needs to be checked
ahead of any other fields. ADDRESS_VALID_FLAG and
ERR_INFO_VALID_FLAG only manages ADDRESS and ERR_INFO
field respectively. driver should continue poll
ERR CNT field even ERR_INFO_VALD_FLAG is not set.

Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com>
Reviewed-by: Tao Zhou <tao.zhou1@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c