iris: Fix util_vma_heap_init size for IRIS_MEMZONE_SHADER
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Mar 2019 21:56:12 +0000 (14:56 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Fri, 22 Mar 2019 02:07:17 +0000 (19:07 -0700)
Fixes assertions when disabling bucket allocators.

src/gallium/drivers/iris/iris_bufmgr.c

index ae335163d45e0499f33c1ef88b20cbde7a557646..e0d167913d2147c2322f534fc2767d1654f7c95a 100644 (file)
@@ -1637,7 +1637,7 @@ iris_bufmgr_init(struct gen_device_info *devinfo, int fd)
    const uint64_t _4GB = 1ull << 32;
 
    util_vma_heap_init(&bufmgr->vma_allocator[IRIS_MEMZONE_SHADER],
-                      PAGE_SIZE, _4GB);
+                      PAGE_SIZE, _4GB - PAGE_SIZE);
    util_vma_heap_init(&bufmgr->vma_allocator[IRIS_MEMZONE_SURFACE],
                       IRIS_MEMZONE_SURFACE_START,
                       _4GB - IRIS_MAX_BINDERS * IRIS_BINDER_SIZE);