Commit b12252b0 authored by Hawking Zhang's avatar Hawking Zhang Committed by Alex Deucher

drm/amdgpu: add structures for rlcg indirect reg access

Add structures that are used to cache registers offsets
for rlcg indirect reg access ctrl and flag availability
of such interface
Signed-off-by: default avatarHawking Zhang <Hawking.Zhang@amd.com>
Reviewed-by: default avatarZhou, Peng Ju <PengJu.Zhou@amd.com>
Acked-by: default avatarChristian König <christian.koenig@amd.com>
Reviewed-by: default avatarLijo Lazar <lijo.lazar@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 7bbe43f8
...@@ -132,6 +132,16 @@ struct amdgpu_rlc_funcs { ...@@ -132,6 +132,16 @@ struct amdgpu_rlc_funcs {
bool (*is_rlcg_access_range)(struct amdgpu_device *adev, uint32_t reg); bool (*is_rlcg_access_range)(struct amdgpu_device *adev, uint32_t reg);
}; };
struct amdgpu_rlcg_reg_access_ctrl {
uint32_t scratch_reg0;
uint32_t scratch_reg1;
uint32_t scratch_reg2;
uint32_t scratch_reg3;
uint32_t grbm_cntl;
uint32_t grbm_idx;
uint32_t spare_int;
};
struct amdgpu_rlc { struct amdgpu_rlc {
/* for power gating */ /* for power gating */
struct amdgpu_bo *save_restore_obj; struct amdgpu_bo *save_restore_obj;
...@@ -191,6 +201,10 @@ struct amdgpu_rlc { ...@@ -191,6 +201,10 @@ struct amdgpu_rlc {
struct amdgpu_bo *rlc_toc_bo; struct amdgpu_bo *rlc_toc_bo;
uint64_t rlc_toc_gpu_addr; uint64_t rlc_toc_gpu_addr;
void *rlc_toc_buf; void *rlc_toc_buf;
bool rlcg_reg_access_supported;
/* registers for rlcg indirect reg access */
struct amdgpu_rlcg_reg_access_ctrl reg_access_ctrl;
}; };
void amdgpu_gfx_rlc_enter_safe_mode(struct amdgpu_device *adev); void amdgpu_gfx_rlc_enter_safe_mode(struct amdgpu_device *adev);
......
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