sna/gen4: Check for peculiar initial values for the surface offset

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Chris Wilson 2012-06-24 13:48:38 +01:00
parent 8f4221a252
commit a87f2b9325
2 changed files with 3 additions and 0 deletions

View File

@ -1270,6 +1270,8 @@ gen4_emit_state_base_address(struct sna *sna)
static void
gen4_emit_invariant(struct sna *sna)
{
assert(sna->kgem.surface == sna->kgem.batch_size);
if (sna->kgem.gen >= 45)
OUT_BATCH(NEW_PIPELINE_SELECT | PIPELINE_SELECT_3D);
else

View File

@ -1155,6 +1155,7 @@ static void __kgem_bo_destroy(struct kgem *kgem, struct kgem_bo *bo)
assert(list_is_empty(&bo->list));
assert(bo->refcnt == 0);
assert(!bo->purged);
bo->binding.offset = 0;
kgem_bo_clear_scanout(kgem, bo);