drm/amdgpu: add flag to indicate the type of RAS eeprom record

One UMC MCA address could map to multiply physical address (PA):

AMDGPU_RAS_EEPROM_REC_PA: one record store one PA
AMDGPU_RAS_EEPROM_REC_MCA: one record store one MCA address, PA
is not cared about

Signed-off-by: Tao Zhou <tao.zhou1@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Tao Zhou
2024-10-18 17:52:59 +08:00
committed by Alex Deucher
parent 95024c714b
commit 772df3df80
2 changed files with 40 additions and 7 deletions

View File

@@ -43,6 +43,19 @@ enum amdgpu_ras_eeprom_err_type {
AMDGPU_RAS_EEPROM_ERR_COUNT,
};
/*
* one UMC MCA address could map to multiply physical address (PA),
* such as 1:16, we use eeprom_table_record.address to store MCA
* address and use eeprom_table_record.retired_page to save PA.
*
* AMDGPU_RAS_EEPROM_REC_PA: one record store one PA
* AMDGPU_RAS_EEPROM_REC_MCA: one record store one MCA address
*/
enum amdgpu_ras_eeprom_rec_type {
AMDGPU_RAS_EEPROM_REC_PA,
AMDGPU_RAS_EEPROM_REC_MCA,
};
struct amdgpu_ras_eeprom_table_header {
uint32_t header;
uint32_t version;
@@ -102,6 +115,7 @@ struct amdgpu_ras_eeprom_control {
/* Record channel info which occurred bad pages
*/
u32 bad_channel_bitmap;
enum amdgpu_ras_eeprom_rec_type rec_type;
};
/*