diff options
author | Dave Airlie <airlied@redhat.com> | 2008-05-28 06:43:40 +1000 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2008-05-28 06:43:40 +1000 |
commit | edce33e87fb79a540d8c285f205d4c3f2c2bc9f4 (patch) | |
tree | ed058a4777d2f7436c437ea769146ead895a37da /src | |
parent | 307bd65a25ee425d8359dd30572b002ce2338f91 (diff) |
radeon: fix surface access on avivo chips.
This should fix VT switch on vesafb
Diffstat (limited to 'src')
-rw-r--r-- | src/radeon_driver.c | 30 |
1 files changed, 20 insertions, 10 deletions
diff --git a/src/radeon_driver.c b/src/radeon_driver.c index 7124b11d..733e9c6b 100644 --- a/src/radeon_driver.c +++ b/src/radeon_driver.c @@ -3224,9 +3224,11 @@ Bool RADEONScreenInit(int scrnIndex, ScreenPtr pScreen, #endif /* Initial setup of surfaces */ - xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, RADEON_LOGLEVEL_DEBUG, - "Setting up initial surfaces\n"); - RADEONChangeSurfaces(pScrn); + if (info->ChipFamily < CHIP_FAMILY_R600) { + xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, RADEON_LOGLEVEL_DEBUG, + "Setting up initial surfaces\n"); + RADEONChangeSurfaces(pScrn); + } /* Memory manager setup */ @@ -3457,10 +3459,12 @@ Bool RADEONScreenInit(int scrnIndex, ScreenPtr pScreen, #endif /* Make sure surfaces are allright since DRI setup may have changed them */ - xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, RADEON_LOGLEVEL_DEBUG, - "Setting up final surfaces\n"); + if (info->ChipFamily < CHIP_FAMILY_R600) { + xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, RADEON_LOGLEVEL_DEBUG, + "Setting up final surfaces\n"); - RADEONChangeSurfaces(pScrn); + RADEONChangeSurfaces(pScrn); + } /* Enable aceleration */ @@ -4037,7 +4041,8 @@ void RADEONChangeSurfaces(ScrnInfoPtr pScrn) } /* Update surface images */ - RADEONSaveSurfaces(pScrn, info->ModeReg); + if (info->ChipFamily < CHIP_FAMILY_R600) + RADEONSaveSurfaces(pScrn, info->ModeReg); } /* Read memory map */ @@ -4808,7 +4813,8 @@ static void RADEONSave(ScrnInfoPtr pScrn) } RADEONSaveBIOSRegisters(pScrn, save); - RADEONSaveSurfaces(pScrn, save); + if (info->ChipFamily < CHIP_FAMILY_R600) + RADEONSaveSurfaces(pScrn, save); } @@ -4864,9 +4870,9 @@ static void RADEONRestore(ScrnInfoPtr pScrn) } RADEONRestoreBIOSRegisters(pScrn, restore); - RADEONRestoreSurfaces(pScrn, restore); } + #if 1 /* Temp fix to "solve" VT switch problems. When switching VTs on * some systems, the console can either hang or the fonts can be @@ -4876,6 +4882,9 @@ static void RADEONRestore(ScrnInfoPtr pScrn) usleep(100000); #endif + if (info->ChipFamily < CHIP_FAMILY_R600) + RADEONRestoreSurfaces(pScrn, restore); + /* 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) { @@ -5275,7 +5284,8 @@ Bool RADEONEnterVT(int scrnIndex, int flags) if (!xf86SetDesiredModes(pScrn)) return FALSE; - RADEONRestoreSurfaces(pScrn, info->ModeReg); + if (info->ChipFamily < CHIP_FAMILY_R600) + RADEONRestoreSurfaces(pScrn, info->ModeReg); #ifdef XF86DRI if (info->directRenderingEnabled) { if (info->cardType == CARD_PCIE && |