[PATCH 2/2] savage: Setup tiled surface registers in SavageEnterVT

Tormod Volden lists.tormod at gmail.com
Sun Jan 23 11:23:49 PST 2011


From: Tormod Volden <debian.tormod at gmail.com>

These registers are cleared after suspend/resume, so set them
up again in EnterVT.
---

Is there any other suitable function that is called on resume,
where this can be placed?

Similar things (registers) are set up in SavageInitialize2DEngine,
but that function is called quite often.

Finally, is there something else to blame for clearing out these
registers? Is pm-utils doing to much?

Cheers,
Tormod

 src/savage_driver.c |    1 +
 src/savage_driver.h |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/savage_driver.c b/src/savage_driver.c
index 38db9f6..1a76c77 100644
--- a/src/savage_driver.c
+++ b/src/savage_driver.c
@@ -2219,6 +2219,7 @@ static Bool SavageEnterVT(int scrnIndex, int flags)
 	pSAREAPriv->ctxOwner = DRIGetContext(pScreen);
         DRIUnlock(pScreen);
         psav->LockHeld = 0;
+        SAVAGEDRISetupTiledSurfaceRegs ( psav );
     }
 #endif
     if (!SAVPTR(pScrn)->IsSecondary)
diff --git a/src/savage_driver.h b/src/savage_driver.h
index 9c0ba58..64587fc 100644
--- a/src/savage_driver.h
+++ b/src/savage_driver.h
@@ -559,6 +559,7 @@ Bool SAVAGEDRIScreenInit( ScreenPtr pScreen );
 Bool SAVAGEInitMC(ScreenPtr pScreen);
 void SAVAGEDRICloseScreen( ScreenPtr pScreen );
 Bool SAVAGEDRIFinishScreenInit( ScreenPtr pScreen );
+void SAVAGEDRISetupTiledSurfaceRegs ( SavagePtr psav );
 
 Bool SAVAGELockUpdate( ScrnInfoPtr pScrn, drmLockFlags flags );
 
-- 
1.7.0.4



More information about the xorg-devel mailing list