diff options
author | Rex Zhu <Rex.Zhu@amd.com> | 2018-09-20 05:06:22 -0400 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2018-09-26 22:09:19 -0400 |
commit | 722ca51d4f50b36bb95da99ae3f4cf371cbc9708 (patch) | |
tree | a6a1c18156b9ac16c995a86d554a322ac686e64a /drivers/gpu/drm | |
parent | 5d944aaa3c473b476d71f91977360411f6ca88d4 (diff) |
drm/amdgpu: Remove redundant code in gfx_v8_0.c
the CG related registers have been programed in golden setting
PG register default value is 0.
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Hang Zhou <hang.zhou@amd.com>
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c index 93d7fe5c94dc..463d07e186d4 100644 --- a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +++ b/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | |||
@@ -4208,31 +4208,11 @@ static int gfx_v8_0_rlc_load_microcode(struct amdgpu_device *adev) | |||
4208 | static int gfx_v8_0_rlc_resume(struct amdgpu_device *adev) | 4208 | static int gfx_v8_0_rlc_resume(struct amdgpu_device *adev) |
4209 | { | 4209 | { |
4210 | int r; | 4210 | int r; |
4211 | u32 tmp; | ||
4212 | 4211 | ||
4213 | gfx_v8_0_rlc_stop(adev); | 4212 | gfx_v8_0_rlc_stop(adev); |
4214 | |||
4215 | /* disable CG */ | ||
4216 | tmp = RREG32(mmRLC_CGCG_CGLS_CTRL); | ||
4217 | tmp &= ~(RLC_CGCG_CGLS_CTRL__CGCG_EN_MASK | | ||
4218 | RLC_CGCG_CGLS_CTRL__CGLS_EN_MASK); | ||
4219 | WREG32(mmRLC_CGCG_CGLS_CTRL, tmp); | ||
4220 | if (adev->asic_type == CHIP_POLARIS11 || | ||
4221 | adev->asic_type == CHIP_POLARIS10 || | ||
4222 | adev->asic_type == CHIP_POLARIS12 || | ||
4223 | adev->asic_type == CHIP_VEGAM) { | ||
4224 | tmp = RREG32(mmRLC_CGCG_CGLS_CTRL_3D); | ||
4225 | tmp &= ~0x3; | ||
4226 | WREG32(mmRLC_CGCG_CGLS_CTRL_3D, tmp); | ||
4227 | } | ||
4228 | |||
4229 | /* disable PG */ | ||
4230 | WREG32(mmRLC_PG_CNTL, 0); | ||
4231 | |||
4232 | gfx_v8_0_rlc_reset(adev); | 4213 | gfx_v8_0_rlc_reset(adev); |
4233 | gfx_v8_0_init_pg(adev); | 4214 | gfx_v8_0_init_pg(adev); |
4234 | 4215 | ||
4235 | |||
4236 | if (adev->firmware.load_type == AMDGPU_FW_LOAD_DIRECT) { | 4216 | if (adev->firmware.load_type == AMDGPU_FW_LOAD_DIRECT) { |
4237 | /* legacy rlc firmware loading */ | 4217 | /* legacy rlc firmware loading */ |
4238 | r = gfx_v8_0_rlc_load_microcode(adev); | 4218 | r = gfx_v8_0_rlc_load_microcode(adev); |