diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2010-12-20 12:35:04 -0500 |
---|---|---|
committer | AK <andi@firstfloor.org> | 2011-02-06 11:03:49 -0800 |
commit | a3f86d59f4f072da1d289a9c12cd4c10fbc3e065 (patch) | |
tree | d5d29a965b8d3413939b1dd9637cd9074600766f | |
parent | 87e27023b169b23410b59e24e579d8d9d55136a8 (diff) | |
download | lwn-a3f86d59f4f072da1d289a9c12cd4c10fbc3e065.tar.gz lwn-a3f86d59f4f072da1d289a9c12cd4c10fbc3e065.zip |
drm/radeon/kms/evergreen: reset the grbm blocks at resume and init
commit 86f5c9edbb3bac37cc8cee6528a929005ba72aad upstream.
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>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
-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 82cc369a85ec..b7e60e562c41 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c @@ -2080,6 +2080,11 @@ int evergreen_resume(struct radeon_device *rdev) { int r; + /* reset the asic, the gfx blocks are often in a bad state + * after the driver is unloaded or after a resume + */ + if (radeon_asic_reset(rdev)) + dev_warn(rdev->dev, "GPU reset failed !\n"); /* Do not reset GPU before posting, on rv770 hw unlike on r500 hw, * posting will perform necessary task to bring back GPU into good * shape. @@ -2181,6 +2186,11 @@ int evergreen_init(struct radeon_device *rdev) r = radeon_atombios_init(rdev); if (r) return r; + /* reset the asic, the gfx blocks are often in a bad state + * after the driver is unloaded or after a resume + */ + if (radeon_asic_reset(rdev)) + dev_warn(rdev->dev, "GPU reset failed !\n"); /* Post card if necessary */ if (!evergreen_card_posted(rdev)) { if (!rdev->bios) { |