diff options
Diffstat (limited to 'src/panfrost/encoder/pan_bo.c')
-rw-r--r-- | src/panfrost/encoder/pan_bo.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/panfrost/encoder/pan_bo.c b/src/panfrost/encoder/pan_bo.c index 32fc84e1363..53249e87301 100644 --- a/src/panfrost/encoder/pan_bo.c +++ b/src/panfrost/encoder/pan_bo.c @@ -31,6 +31,8 @@ #include "drm-uapi/panfrost_drm.h" #include "pan_bo.h" +#include "pan_util.h" +#include "../pandecode/public.h" #include "os/os_mman.h" @@ -405,6 +407,13 @@ panfrost_bo_create(struct panfrost_device *dev, size_t size, _mesa_set_add(bo->dev->active_bos, bo); pthread_mutex_unlock(&dev->active_bos_lock); + if (dev->debug & (PAN_DBG_TRACE | PAN_DBG_SYNC)) { + if (flags & PAN_BO_INVISIBLE) + pandecode_inject_mmap(bo->gpu, NULL, bo->size, NULL); + else if (!(flags & PAN_BO_DELAY_MMAP)) + pandecode_inject_mmap(bo->gpu, bo->cpu, bo->size, NULL); + } + return bo; } |