diff options
author | Alex Deucher <alexander.deucher@amd.com> | 2013-01-23 18:57:56 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2013-01-31 16:24:55 -0500 |
commit | b21b6e7aab9d0ee97f6d3cf3654fda4348b3b7ea (patch) | |
tree | c14d7625df864e8ca4340f71f3c35a8d98a6c8d3 | |
parent | ca57802e521de54341efc8a56f70571f79ffac72 (diff) |
drm/radeon: halt engines before disabling MC (evergreen)
It's better to halt the engines before we disable the MC.
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r-- | drivers/gpu/drm/radeon/evergreen.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c index fd5e0025b656..f77e33262274 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c | |||
@@ -2460,11 +2460,6 @@ static void evergreen_gpu_soft_reset(struct radeon_device *rdev, u32 reset_mask) | |||
2460 | 2460 | ||
2461 | evergreen_print_gpu_status_regs(rdev); | 2461 | evergreen_print_gpu_status_regs(rdev); |
2462 | 2462 | ||
2463 | evergreen_mc_stop(rdev, &save); | ||
2464 | if (evergreen_mc_wait_for_idle(rdev)) { | ||
2465 | dev_warn(rdev->dev, "Wait for MC idle timedout !\n"); | ||
2466 | } | ||
2467 | |||
2468 | /* Disable CP parsing/prefetching */ | 2463 | /* Disable CP parsing/prefetching */ |
2469 | WREG32(CP_ME_CNTL, CP_ME_HALT | CP_PFP_HALT); | 2464 | WREG32(CP_ME_CNTL, CP_ME_HALT | CP_PFP_HALT); |
2470 | 2465 | ||
@@ -2475,6 +2470,13 @@ static void evergreen_gpu_soft_reset(struct radeon_device *rdev, u32 reset_mask) | |||
2475 | WREG32(DMA_RB_CNTL, tmp); | 2470 | WREG32(DMA_RB_CNTL, tmp); |
2476 | } | 2471 | } |
2477 | 2472 | ||
2473 | udelay(50); | ||
2474 | |||
2475 | evergreen_mc_stop(rdev, &save); | ||
2476 | if (evergreen_mc_wait_for_idle(rdev)) { | ||
2477 | dev_warn(rdev->dev, "Wait for MC idle timedout !\n"); | ||
2478 | } | ||
2479 | |||
2478 | if (reset_mask & (RADEON_RESET_GFX | RADEON_RESET_COMPUTE)) { | 2480 | if (reset_mask & (RADEON_RESET_GFX | RADEON_RESET_COMPUTE)) { |
2479 | grbm_soft_reset |= SOFT_RESET_DB | | 2481 | grbm_soft_reset |= SOFT_RESET_DB | |
2480 | SOFT_RESET_CB | | 2482 | SOFT_RESET_CB | |