drm/radeon/kms: R3XX-R4XX fix GPU reset code
authorJerome Glisse <jglisse@redhat.com>
Mon, 26 Apr 2010 20:23:42 +0000 (22:23 +0200)
committerDave Airlie <airlied@redhat.com>
Mon, 26 Apr 2010 23:48:16 +0000 (09:48 +1000)
commita1e9ada3e148dc300fdd25705bd3ac024897dc68
tree3cd724dc3b385553f228dcd310c10b6f32f23ec6
parentf2594933df9719bd2b0aaaa8ea9b2b850d6e1c42
drm/radeon/kms: R3XX-R4XX fix GPU reset code

Previous reset code leaded to computer hard lockup (need to unplug
the power too reboot the computer) on various configuration. This
patch change the reset code to avoid hard lockup. The GPU reset
is failing most of the time but at least user can log in remotely
or properly shutdown the computer.

Two issues were leading to hard lockup :
- Writting to the scratch register lead to hard lockup most likely
because the write back mecanism is in fuzy state after GPU lockup.
- Resetting the GPU memory controller and not reinitializing it
after leaded to hard lockup. We did only reinitialize in case of
successfull reset thus unsuccessfull reset quickly leaded to hard
lockup.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/radeon/r300.c
drivers/gpu/drm/radeon/radeon_fence.c