diff --git a/src/gallium/drivers/iris/iris_bufmgr.c b/src/gallium/drivers/iris/iris_bufmgr.c index 6c72e24a1e5..e04712a2540 100644 --- a/src/gallium/drivers/iris/iris_bufmgr.c +++ b/src/gallium/drivers/iris/iris_bufmgr.c @@ -1079,8 +1079,14 @@ iris_bo_alloc(struct iris_bufmgr *bufmgr, (bufmgr->vram.size > 0 && !local) || (flags & BO_ALLOC_COHERENT); bool is_scanout = (flags & BO_ALLOC_SCANOUT) != 0; - enum iris_mmap_mode mmap_mode = - !local && is_coherent && !is_scanout ? IRIS_MMAP_WB : IRIS_MMAP_WC; + + enum iris_mmap_mode mmap_mode; + if (!bufmgr->all_vram_mappable && heap == IRIS_HEAP_DEVICE_LOCAL) + mmap_mode = IRIS_MMAP_NONE; + else if (!local && is_coherent && !is_scanout) + mmap_mode = IRIS_MMAP_WB; + else + mmap_mode = IRIS_MMAP_WC; simple_mtx_lock(&bufmgr->lock);