diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2010-12-20 12:35:04 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2010-12-20 21:53:05 -0500 |
commit | 86f5c9edbb3bac37cc8cee6528a929005ba72aad (patch) | |
tree | b804c064969e5e8a57bff48e8e9985d92e593aa1 /drivers/gpu | |
parent | 9f0c4f9c2f835eee1bbb93f96bf9483d56f1892b (diff) |
drm/radeon/kms/evergreen: reset the grbm blocks at resume and init
This fixes module reloading and resume as the gfx block seems to
be left in a bad state in some cases.
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/radeon/evergreen.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c index 6ced1ba2bee8..7b337c361a12 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c | |||
@@ -2583,6 +2583,11 @@ int evergreen_resume(struct radeon_device *rdev) | |||
2583 | { | 2583 | { |
2584 | int r; | 2584 | int r; |
2585 | 2585 | ||
2586 | /* reset the asic, the gfx blocks are often in a bad state | ||
2587 | * after the driver is unloaded or after a resume | ||
2588 | */ | ||
2589 | if (radeon_asic_reset(rdev)) | ||
2590 | dev_warn(rdev->dev, "GPU reset failed !\n"); | ||
2586 | /* Do not reset GPU before posting, on rv770 hw unlike on r500 hw, | 2591 | /* Do not reset GPU before posting, on rv770 hw unlike on r500 hw, |
2587 | * posting will perform necessary task to bring back GPU into good | 2592 | * posting will perform necessary task to bring back GPU into good |
2588 | * shape. | 2593 | * shape. |
@@ -2699,6 +2704,11 @@ int evergreen_init(struct radeon_device *rdev) | |||
2699 | r = radeon_atombios_init(rdev); | 2704 | r = radeon_atombios_init(rdev); |
2700 | if (r) | 2705 | if (r) |
2701 | return r; | 2706 | return r; |
2707 | /* reset the asic, the gfx blocks are often in a bad state | ||
2708 | * after the driver is unloaded or after a resume | ||
2709 | */ | ||
2710 | if (radeon_asic_reset(rdev)) | ||
2711 | dev_warn(rdev->dev, "GPU reset failed !\n"); | ||
2702 | /* Post card if necessary */ | 2712 | /* Post card if necessary */ |
2703 | if (!evergreen_card_posted(rdev)) { | 2713 | if (!evergreen_card_posted(rdev)) { |
2704 | if (!rdev->bios) { | 2714 | if (!rdev->bios) { |