summaryrefslogtreecommitdiff
path: root/src/intel_uxa.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/intel_uxa.c')
-rw-r--r--src/intel_uxa.c25
1 files changed, 14 insertions, 11 deletions
diff --git a/src/intel_uxa.c b/src/intel_uxa.c
index 30717d0c..9e58c694 100644
--- a/src/intel_uxa.c
+++ b/src/intel_uxa.c
@@ -340,13 +340,6 @@ static void intel_uxa_solid(PixmapPtr pixmap, int x1, int y1, int x2, int y2)
}
}
-static void intel_uxa_done_solid(PixmapPtr pixmap)
-{
- ScrnInfoPtr scrn = xf86Screens[pixmap->drawable.pScreen->myNum];
-
- intel_debug_flush(scrn);
-}
-
/**
* TODO:
* - support planemask using FULL_BLT_CMD?
@@ -501,9 +494,19 @@ intel_uxa_copy(PixmapPtr dest, int src_x1, int src_y1, int dst_x1,
}
}
-static void intel_uxa_done_copy(PixmapPtr dest)
+static void intel_uxa_done(PixmapPtr pixmap)
{
- ScrnInfoPtr scrn = xf86Screens[dest->drawable.pScreen->myNum];
+ ScrnInfoPtr scrn = xf86Screens[pixmap->drawable.pScreen->myNum];
+ intel_screen_private *intel = intel_get_screen_private(scrn);
+
+ if (IS_GEN6(intel) || IS_GEN7(intel)) {
+ /* workaround a random BLT hang */
+ BEGIN_BATCH_BLT(3);
+ OUT_BATCH(XY_SETUP_CLIP_BLT_CMD);
+ OUT_BATCH(0);
+ OUT_BATCH(0);
+ ADVANCE_BATCH();
+ }
intel_debug_flush(scrn);
}
@@ -1225,13 +1228,13 @@ Bool intel_uxa_init(ScreenPtr screen)
intel->uxa_driver->check_solid = intel_uxa_check_solid;
intel->uxa_driver->prepare_solid = intel_uxa_prepare_solid;
intel->uxa_driver->solid = intel_uxa_solid;
- intel->uxa_driver->done_solid = intel_uxa_done_solid;
+ intel->uxa_driver->done_solid = intel_uxa_done;
/* Copy */
intel->uxa_driver->check_copy = intel_uxa_check_copy;
intel->uxa_driver->prepare_copy = intel_uxa_prepare_copy;
intel->uxa_driver->copy = intel_uxa_copy;
- intel->uxa_driver->done_copy = intel_uxa_done_copy;
+ intel->uxa_driver->done_copy = intel_uxa_done;
/* Composite */
if (IS_GEN2(intel)) {