mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 04:38:03 +02:00
freedreno/drm/virtio: Guest side fence waits
Now that fd_fence and fd_submit_fence are unified, we can wait on the fence fd rather than needing to poll the host. Signed-off-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20263>
This commit is contained in:
parent
995c64ddcb
commit
90b9b1330d
1 changed files with 5 additions and 0 deletions
|
|
@ -21,6 +21,7 @@
|
|||
* SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "util/libsync.h"
|
||||
#include "util/slab.h"
|
||||
|
||||
#include "freedreno_ringbuffer_sp.h"
|
||||
|
|
@ -120,6 +121,10 @@ static int
|
|||
virtio_pipe_wait(struct fd_pipe *pipe, const struct fd_fence *fence, uint64_t timeout)
|
||||
{
|
||||
MESA_TRACE_FUNC();
|
||||
|
||||
if (fence->use_fence_fd)
|
||||
return sync_wait(fence->fence_fd, timeout / 1000000);
|
||||
|
||||
struct msm_ccmd_wait_fence_req req = {
|
||||
.hdr = MSM_CCMD(WAIT_FENCE, sizeof(req)),
|
||||
.queue_id = to_virtio_pipe(pipe)->queue_id,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue