summaryrefslogtreecommitdiff
path: root/src/i830_driver.c
diff options
context:
space:
mode:
authorWang Zhenyu <zhenyu.z.wang@intel.com>2007-01-03 22:37:32 -0800
committerKeith Packard <keithp@neko.keithp.com>2007-01-06 14:40:27 -0800
commit71946bcdc3c68c220996afac944698eea1974a36 (patch)
tree64ccbabbfa09067540a51077b9096baf16b1524b /src/i830_driver.c
parent35cebed70827999812f8343ac97ad0dffda20786 (diff)
[PATCH] Add rotation support for 965.
Diffstat (limited to 'src/i830_driver.c')
-rw-r--r--src/i830_driver.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 6b76d12a..ffa391fc 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -2534,6 +2534,10 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
/* Rotated2 Buffer */
memset(&(pI830->RotatedMem2), 0, sizeof(pI830->RotatedMem2));
pI830->RotatedMem2.Key = -1;
+ if (IS_I965G(pI830)) {
+ memset(&(pI830->RotateStateMem), 0, sizeof(pI830->RotateStateMem));
+ pI830->RotateStateMem.Key = -1;
+ }
}
#ifdef HAS_MTRR_SUPPORT
@@ -2902,11 +2906,7 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
shadowSetup(pScreen);
/* support all rotations */
xf86RandR12Init (pScreen);
- if (IS_I965G(pI830)) {
- xf86RandR12SetRotations (pScreen, RR_Rotate_0); /* only 0 degrees for I965G */
- } else {
- xf86RandR12SetRotations (pScreen, RR_Rotate_0 | RR_Rotate_90 | RR_Rotate_180 | RR_Rotate_270);
- }
+ xf86RandR12SetRotations (pScreen, RR_Rotate_0 | RR_Rotate_90 | RR_Rotate_180 | RR_Rotate_270);
pI830->PointerMoved = pScrn->PointerMoved;
pScrn->PointerMoved = I830PointerMoved;
pI830->CreateScreenResources = pScreen->CreateScreenResources;
@@ -3249,8 +3249,7 @@ I830SwitchMode(int scrnIndex, DisplayModePtr mode, int flags)
* The extra WindowTable check detects a rotation at startup.
*/
if ( (!WindowTable[pScrn->scrnIndex] || pspix->devPrivate.ptr == NULL) &&
- !pI830->DGAactive && (pScrn->PointerMoved == I830PointerMoved) &&
- !IS_I965G(pI830)) {
+ !pI830->DGAactive && (pScrn->PointerMoved == I830PointerMoved)) {
if (!I830Rotate(pScrn, mode))
ret = FALSE;
}