sna: Only promote to full GPU if we already have a GPU bo

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Chris Wilson 2012-07-10 17:05:20 +01:00
parent 232217eef8
commit 747ed0ca28
1 changed files with 1 additions and 1 deletions

View File

@ -10393,7 +10393,7 @@ sna_poly_fill_rect(DrawablePtr draw, GCPtr gc, int n, xRectangle *rect)
if (region_subsumes_drawable(&region, &pixmap->drawable) ||
box_inplace(pixmap, &region.extents)) {
DBG(("%s: promoting to full GPU\n", __FUNCTION__));
if (priv->cpu_damage == NULL) {
if (priv->gpu_bo && priv->cpu_damage == NULL) {
sna_damage_all(&priv->gpu_damage,
pixmap->drawable.width,
pixmap->drawable.height);