summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlex Deucher <alex@botch2.(none)>2007-12-24 01:11:56 -0500
committerAlex Deucher <alex@botch2.(none)>2007-12-24 01:11:56 -0500
commit653da558148cc601bc1f80253e92ef98c75ef37a (patch)
tree4479c83df3e359ebd5a2e1fbccf27840d032e377 /src
parentad3325f672a241449ca239c8ee3a24b6d7703d76 (diff)
RADEON: restore crtc regs before VGA regs.
It seems some radeons don't restore text console properly if the crtc regs are restored after the VGA regs. Thanks to Sverre Froyen for helping me track this down
Diffstat (limited to 'src')
-rw-r--r--src/radeon_driver.c23
1 files changed, 12 insertions, 11 deletions
diff --git a/src/radeon_driver.c b/src/radeon_driver.c
index 6885cdc..7ce9236 100644
--- a/src/radeon_driver.c
+++ b/src/radeon_driver.c
@@ -4590,6 +4590,18 @@ void RADEONRestore(ScrnInfoPtr pScrn)
usleep(100000);
#endif
+ /* need to make sure we don't enable a crtc by accident or we may get a hang */
+ if (pRADEONEnt->HasCRTC2 && !info->IsSecondary) {
+ if (info->crtc2_on && xf86_config->num_crtc > 1) {
+ crtc = xf86_config->crtc[1];
+ crtc->funcs->dpms(crtc, DPMSModeOn);
+ }
+ }
+ if (info->crtc_on) {
+ crtc = xf86_config->crtc[0];
+ crtc->funcs->dpms(crtc, DPMSModeOn);
+ }
+
#ifdef WITH_VGAHW
if (info->VGAAccess) {
vgaHWPtr hwp = VGAHWPTR(pScrn);
@@ -4606,17 +4618,6 @@ void RADEONRestore(ScrnInfoPtr pScrn)
}
#endif
- /* need to make sure we don't enable a crtc by accident or we may get a hang */
- if (pRADEONEnt->HasCRTC2 && !info->IsSecondary) {
- if (info->crtc2_on && xf86_config->num_crtc > 1) {
- crtc = xf86_config->crtc[1];
- crtc->funcs->dpms(crtc, DPMSModeOn);
- }
- }
- if (info->crtc_on) {
- crtc = xf86_config->crtc[0];
- crtc->funcs->dpms(crtc, DPMSModeOn);
- }
/* to restore console mode, DAC registers should be set after every other registers are set,
* otherwise,we may get blank screen
*/