mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-20 22:30:12 +01:00
panvk: Flush pending map syncs before submission
Flush deferred CPU sync ops so we can make CPU changes visible to the GPU. This is currently a NOP because we haven't enabled cached mappings in panvk yet, but we need to prepare for that before we progressively switch each relevant buffer to use writeback CPU mappings. Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com> Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36385>
This commit is contained in:
parent
3ae96f3cfd
commit
1e6ea0697a
2 changed files with 10 additions and 0 deletions
|
|
@ -511,6 +511,8 @@ init_subqueue(struct panvk_gpu_queue *queue, enum panvk_subqueue_id subqueue)
|
||||||
.queue_submits = DRM_PANTHOR_OBJ_ARRAY(1, &qsubmit),
|
.queue_submits = DRM_PANTHOR_OBJ_ARRAY(1, &qsubmit),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
pan_kmod_flush_bo_map_syncs(dev->kmod.dev);
|
||||||
|
|
||||||
int ret = pan_kmod_ioctl(dev->drm_fd, DRM_IOCTL_PANTHOR_GROUP_SUBMIT,
|
int ret = pan_kmod_ioctl(dev->drm_fd, DRM_IOCTL_PANTHOR_GROUP_SUBMIT,
|
||||||
&gsubmit);
|
&gsubmit);
|
||||||
if (ret)
|
if (ret)
|
||||||
|
|
@ -1136,6 +1138,10 @@ panvk_queue_submit_ioctl(struct panvk_queue_submit *submit)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Flush pending synchronization requests before submitting the job, to
|
||||||
|
* make sure things are GPU-visible. */
|
||||||
|
pan_kmod_flush_bo_map_syncs(dev->kmod.dev);
|
||||||
|
|
||||||
struct drm_panthor_group_submit gsubmit = {
|
struct drm_panthor_group_submit gsubmit = {
|
||||||
.group_handle = queue->group_handle,
|
.group_handle = queue->group_handle,
|
||||||
.queue_submits =
|
.queue_submits =
|
||||||
|
|
|
||||||
|
|
@ -56,6 +56,10 @@ panvk_queue_submit_batch(struct panvk_gpu_queue *queue, struct panvk_batch *batc
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Flush pending synchronization requests before submitting the job, to
|
||||||
|
* make sure things are GPU-visible. */
|
||||||
|
pan_kmod_flush_bo_map_syncs(dev->kmod.dev);
|
||||||
|
|
||||||
if (batch->vtc_jc.first_job) {
|
if (batch->vtc_jc.first_job) {
|
||||||
struct drm_panfrost_submit submit = {
|
struct drm_panfrost_submit submit = {
|
||||||
.bo_handles = (uintptr_t)bos,
|
.bo_handles = (uintptr_t)bos,
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue