Commit 8090b04a authored by Alex Deucher's avatar Alex Deucher Committed by Tim Gardner

drm/amdgpu: Add some tweaks to gfx 8 soft reset

BugLink: http://bugs.launchpad.net/bugs/1546572Reviewed-by: default avatarJunwei Zhang <Jerry.Zhang@amd.com>
Reviewed-by: default avatarChristian König <christian.koenig@amd.com>
Reviewed-by: default avatarKen Wang <Qingqing.Wang@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
(cherry picked from commit 7776a693)
Signed-off-by: default avatarAlberto Milone <alberto.milone@canonical.com>
Signed-off-by: default avatarTim Gardner <tim.gardner@canonical.com>
parent 93a00b8a
...@@ -4687,7 +4687,18 @@ static int gfx_v8_0_soft_reset(void *handle) ...@@ -4687,7 +4687,18 @@ static int gfx_v8_0_soft_reset(void *handle)
gfx_v8_0_cp_gfx_enable(adev, false); gfx_v8_0_cp_gfx_enable(adev, false);
/* Disable MEC parsing/prefetching */ /* Disable MEC parsing/prefetching */
/* XXX todo */ gfx_v8_0_cp_compute_enable(adev, false);
if (grbm_soft_reset || srbm_soft_reset) {
tmp = RREG32(mmGMCON_DEBUG);
tmp = REG_SET_FIELD(tmp,
GMCON_DEBUG, GFX_STALL, 1);
tmp = REG_SET_FIELD(tmp,
GMCON_DEBUG, GFX_CLEAR, 1);
WREG32(mmGMCON_DEBUG, tmp);
udelay(50);
}
if (grbm_soft_reset) { if (grbm_soft_reset) {
tmp = RREG32(mmGRBM_SOFT_RESET); tmp = RREG32(mmGRBM_SOFT_RESET);
...@@ -4716,6 +4727,16 @@ static int gfx_v8_0_soft_reset(void *handle) ...@@ -4716,6 +4727,16 @@ static int gfx_v8_0_soft_reset(void *handle)
WREG32(mmSRBM_SOFT_RESET, tmp); WREG32(mmSRBM_SOFT_RESET, tmp);
tmp = RREG32(mmSRBM_SOFT_RESET); tmp = RREG32(mmSRBM_SOFT_RESET);
} }
if (grbm_soft_reset || srbm_soft_reset) {
tmp = RREG32(mmGMCON_DEBUG);
tmp = REG_SET_FIELD(tmp,
GMCON_DEBUG, GFX_STALL, 0);
tmp = REG_SET_FIELD(tmp,
GMCON_DEBUG, GFX_CLEAR, 0);
WREG32(mmGMCON_DEBUG, tmp);
}
/* Wait a little for things to settle down */ /* Wait a little for things to settle down */
udelay(50); udelay(50);
gfx_v8_0_print_status((void *)adev); gfx_v8_0_print_status((void *)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