summaryrefslogtreecommitdiff
path: root/src/i830_dga.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2006-09-27 16:38:01 -0700
committerEric Anholt <eric@anholt.net>2006-09-27 16:38:01 -0700
commit6ea16bf6b06c8b3aed4d2c98679ab28304d1b56c (patch)
tree1f711e8fb7338d6bee527d084a6ea12421087d79 /src/i830_dga.c
parentfdb6de663579d3b9f31bf9e8a93430b8505ca73f (diff)
parentb970166eab95ac024ff481b0f5fd9aaf3644aabf (diff)
Merge branch 'master' into modesetting
This reverts most of the mergedfb code. This will instead be done in device- independent RandR code. Conflicts: src/Makefile.am src/i810_driver.c src/i810_reg.h src/i830.h src/i830_cursor.c src/i830_driver.c src/i830_modes.c src/i830_video.c
Diffstat (limited to 'src/i830_dga.c')
-rw-r--r--src/i830_dga.c19
1 files changed, 16 insertions, 3 deletions
diff --git a/src/i830_dga.c b/src/i830_dga.c
index 1129fa31..1a6e4e69 100644
--- a/src/i830_dga.c
+++ b/src/i830_dga.c
@@ -253,12 +253,25 @@ static void
I830_Sync(ScrnInfoPtr pScrn)
{
I830Ptr pI830 = I830PTR(pScrn);
+ int flags = MI_WRITE_DIRTY_STATE | MI_INVALIDATE_MAP_CACHE;
MARKER();
- if (pI830->AccelInfoRec) {
- (*pI830->AccelInfoRec->Sync) (pScrn);
- }
+ if (pI830->noAccel)
+ return;
+
+ if (IS_I965G(pI830))
+ flags = 0;
+
+ BEGIN_LP_RING(2);
+ OUT_RING(MI_FLUSH | flags);
+ OUT_RING(MI_NOOP); /* pad to quadword */
+ ADVANCE_LP_RING();
+
+ I830WaitLpRing(pScrn, pI830->LpRing->mem.Size - 8, 0);
+
+ pI830->LpRing->space = pI830->LpRing->mem.Size - 8;
+ pI830->nextColorExpandBuf = 0;
}
static void