drm/amdgpu: Restore HQD persistent state register
authorLijo Lazar <lijo.lazar@amd.com>
Tue, 25 Jul 2023 05:30:08 +0000 (11:00 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 25 Jul 2023 20:26:38 +0000 (16:26 -0400)
commitbc1688fce2ec7726112276650762275392d1bab1
treea5646402159fa000a8d69588f012ecc4784738f3
parent38ac4e8385ffb275b1837986ca6c16f26ea028c5
drm/amdgpu: Restore HQD persistent state register

On GFX v9.4.3, compute queue MQD is populated using the values in HQD
persistent state register. Hence don't clear the values on module
unload, instead restore it to the default reset value so that MQD is
initialized correctly during next module load. In particular, preload
flag needs to be set on compute queue MQD, otherwise it could cause
uninitialized values being used at device reset state resulting in EDC.

Signed-off-by: Lijo Lazar <lijo.lazar@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Reviewed-by: Asad Kamal <asad.kamal@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c