Fix double-counting of low_offset in block->virtual.
authorEric Anholt <eric@anholt.net>
Fri, 18 May 2007 19:57:34 +0000 (12:57 -0700)
committerEric Anholt <eric@anholt.net>
Fri, 18 May 2007 19:57:34 +0000 (12:57 -0700)
src/mesa/drivers/dri/common/dri_bufmgr_fake.c

index 191e16a..1820da5 100644 (file)
@@ -214,7 +214,8 @@ alloc_block(dri_bo *bo)
     */
    insert_at_tail(&bufmgr_fake->lru, block);
 
-   block->virtual = bufmgr_fake->virtual + block->mem->ofs;
+   block->virtual = bufmgr_fake->virtual +
+      block->mem->ofs - bufmgr_fake->low_offset;
    block->bo = bo;
 
    bo_fake->block = block;