diff options
Diffstat (limited to 'src/sna/sna_accel.c')
-rw-r--r-- | src/sna/sna_accel.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c index e12cb073..25b69c93 100644 --- a/src/sna/sna_accel.c +++ b/src/sna/sna_accel.c @@ -2659,6 +2659,7 @@ sna_drawable_use_bo(DrawablePtr drawable, unsigned flags, const BoxRec *box, DBG(("%s: cached upload proxy, discard and revert to GPU\n", __FUNCTION__)); assert(priv->gpu_damage == NULL); + assert(!priv->pinned); kgem_bo_destroy(&to_sna_from_pixmap(pixmap)->kgem, priv->gpu_bo); priv->gpu_bo = NULL; @@ -3100,6 +3101,7 @@ sna_pixmap_move_to_gpu(PixmapPtr pixmap, unsigned flags) if (flags & MOVE_WRITE && priv->gpu_bo && priv->gpu_bo->proxy) { DBG(("%s: discarding cached upload buffer\n", __FUNCTION__)); assert(priv->gpu_damage == NULL); + assert(!priv->pinned); kgem_bo_destroy(&sna->kgem, priv->gpu_bo); priv->gpu_bo = NULL; } @@ -4274,6 +4276,7 @@ sna_copy_boxes(DrawablePtr src, DrawablePtr dst, GCPtr gc, if (region_subsumes_damage(region, dst_priv->cpu_damage)) { DBG(("%s: discarding existing CPU damage\n", __FUNCTION__)); if (dst_priv->gpu_bo && dst_priv->gpu_bo->proxy) { + assert(!dst_priv->pinned); kgem_bo_destroy(&sna->kgem, dst_priv->gpu_bo); dst_priv->gpu_bo = NULL; } @@ -11815,6 +11818,7 @@ sna_poly_fill_rect(DrawablePtr draw, GCPtr gc, int n, xRectangle *rect) DBG(("%s: discarding existing CPU damage\n", __FUNCTION__)); if (priv->gpu_bo && priv->gpu_bo->proxy) { assert(priv->gpu_damage == NULL); + assert(!priv->pinned); kgem_bo_destroy(&sna->kgem, priv->gpu_bo); priv->gpu_bo = NULL; } |