sna: Release the stale GTT mapping after recreating the bo with new tiling
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
8dd913fd3a
commit
ca2a07adc4
|
|
@ -371,10 +371,16 @@ struct kgem_bo *sna_pixmap_change_tiling(PixmapPtr pixmap, uint32_t tiling)
|
|||
&box, 1)) {
|
||||
DBG(("%s: copy failed\n", __FUNCTION__));
|
||||
kgem_bo_destroy(&sna->kgem, bo);
|
||||
return false;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
kgem_bo_destroy(&sna->kgem, priv->gpu_bo);
|
||||
|
||||
if (priv->mapped) {
|
||||
pixmap->devPrivate.ptr = NULL;
|
||||
priv->mapped = 0;
|
||||
}
|
||||
|
||||
return priv->gpu_bo = bo;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue