diff options
| author | Tao Zhou <[email protected]> | 2025-04-10 11:29:57 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2025-05-13 13:32:01 +0000 |
| commit | 699bff37a56c814c414f5b7ca9e49ef8aae660b9 (patch) | |
| tree | c9660c06265657ca8bb0409547cbcb6bb0db54f7 /drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h | |
| parent | drm/amdgpu: add vcn v5_0_0 ip headers (diff) | |
| download | kernel-699bff37a56c814c414f5b7ca9e49ef8aae660b9.tar.gz kernel-699bff37a56c814c414f5b7ca9e49ef8aae660b9.zip | |
drm/amdgpu: add get_retire_flip_bits for UMC
Add the general interface to get flip bits for RAS bad page retirement.
Signed-off-by: Tao Zhou <[email protected]>
Reviewed-by: Hawking Zhang <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h index 857693bcd8d4..78a8b8654573 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_umc.h @@ -78,6 +78,18 @@ #define UMC_NPS_SHIFT 40 #define UMC_NPS_MASK 0xffULL +/* three column bits and one row bit in MCA address flip + * in bad page retirement + */ +#define RETIRE_FLIP_BITS_NUM 4 + +struct amdgpu_umc_flip_bits { + uint32_t flip_bits_in_pa[RETIRE_FLIP_BITS_NUM]; + uint32_t flip_row_bit; + uint32_t r13_in_pa; + uint32_t bit_num; +}; + typedef int (*umc_func)(struct amdgpu_device *adev, uint32_t node_inst, uint32_t umc_inst, uint32_t ch_inst, void *data); @@ -100,6 +112,7 @@ struct amdgpu_umc_ras { bool dump_addr); uint32_t (*get_die_id_from_pa)(struct amdgpu_device *adev, uint64_t mca_addr, uint64_t retired_page); + void (*get_retire_flip_bits)(struct amdgpu_device *adev); }; struct amdgpu_umc_funcs { @@ -130,6 +143,8 @@ struct amdgpu_umc { /* active mask for umc node instance */ unsigned long active_mask; + + struct amdgpu_umc_flip_bits flip_bits; }; int amdgpu_umc_ras_sw_init(struct amdgpu_device *adev); |
