From 26f8ab5429a554801641415f0ab3b2d68cea1d00 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Mon, 4 Jul 2016 10:11:50 +0100 Subject: sna: Restore local damage processing for TearFree/DRI2/swcursor early We currently hack TearFree/DRI2/swcursor to avoid recursion from inside the SwapBuffers to handle the swcursor. This has the issue of a trailing cursor on the boundary of the DRI2 drawable, but prevents the explosion from swapping TearFree buffers from within the TearFree handler (i.e. recursion). This only has to apply to the damage processing before the swap. Signed-off-by: Chris Wilson --- src/sna/sna_dri2.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/sna/sna_dri2.c') diff --git a/src/sna/sna_dri2.c b/src/sna/sna_dri2.c index 38384681..4ec0ccaa 100644 --- a/src/sna/sna_dri2.c +++ b/src/sna/sna_dri2.c @@ -1037,8 +1037,8 @@ static void set_bo(PixmapPtr pixmap, struct kgem_bo *bo) assert(bo->flush); if (APPLY_DAMAGE) { - DamageRegionProcessPending(&pixmap->drawable); sna->ignore_copy_area = false; + DamageRegionProcessPending(&pixmap->drawable); } } @@ -1394,8 +1394,8 @@ __sna_dri2_copy_region(struct sna *sna, DrawablePtr draw, RegionPtr region, } if (APPLY_DAMAGE || flags & DRI2_DAMAGE) { - DamageRegionProcessPending(&pixmap->drawable); sna->ignore_copy_area = false; + DamageRegionProcessPending(&pixmap->drawable); } if (clip.data) @@ -2421,8 +2421,8 @@ static void sna_dri2_xchg_crtc(struct sna *sna, DrawablePtr draw, xf86CrtcPtr cr } sna_shadow_set_crtc(sna, crtc, get_private(back)->bo); if (APPLY_DAMAGE) { - DamageRegionProcessPending(&win->drawable); sna->ignore_copy_area = false; + DamageRegionProcessPending(&win->drawable); } if (priv->front == NULL) { -- cgit v1.2.3