diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2008-10-01 18:53:15 -0400 |
---|---|---|
committer | Alex Deucher <alexdeucher@gmail.com> | 2008-10-01 18:53:15 -0400 |
commit | 4ac6e499089aec3c79af5dbede5fe631b105ce3d (patch) | |
tree | 9f25eb3ed6f786dcf541f20af1fb1c7fbb569339 /src/radeon_driver.c | |
parent | 346228b20c69a965c9e7d67157f42c1d36a5b6c3 (diff) |
proper fix for initial rotation
The initial modeset was setting the MC regs, so just set them
rather than the full modeset.
Diffstat (limited to 'src/radeon_driver.c')
-rw-r--r-- | src/radeon_driver.c | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/src/radeon_driver.c b/src/radeon_driver.c index 9b36ca4d..eac07d0e 100644 --- a/src/radeon_driver.c +++ b/src/radeon_driver.c @@ -3514,24 +3514,11 @@ Bool RADEONScreenInit(int scrnIndex, ScreenPtr pScreen, pScrn->vtSema = TRUE; - /* XXX - * Unless we set an initial mode here, RADEONDRIKernelInit() hangs in the ioctl - * to initialize the CP. However, we need to init the CP for accel or initial - * rotation fails so we set the mode now, then call xf86SetDesiredModes() after - * accel is initialized to set the proper rotation, etc. + /* restore the memory map here otherwise we may get a hang when + * initializing the drm below */ - { - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn); - int i; - for (i = 0; i < config->num_crtc; i++) { - xf86CrtcPtr crtc = config->crtc[i]; - if (crtc->enabled) - xf86CrtcSetMode (crtc, &crtc->desiredMode, RR_Rotate_0, - crtc->desiredX, crtc->desiredY); - } - } - - RADEONSaveScreen(pScreen, SCREEN_SAVER_ON); + RADEONInitMemMapRegisters(pScrn, info->ModeReg, info); + RADEONRestoreMemMapRegisters(pScrn, info->ModeReg); /* Backing store setup */ xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, RADEON_LOGLEVEL_DEBUG, |