[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v1 4/6] virtio-gpu: Handle virgl fence creation errors
From: |
Dmitry Osipenko |
Subject: |
[PATCH v1 4/6] virtio-gpu: Handle virgl fence creation errors |
Date: |
Mon, 7 Oct 2024 02:23:46 +0300 |
Print out error messages when virgl fence creation fails to aid debugging
of the fence-related bugs.
Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
---
hw/display/virtio-gpu-virgl.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/hw/display/virtio-gpu-virgl.c b/hw/display/virtio-gpu-virgl.c
index eedae7357f1a..b32ce44ba2b1 100644
--- a/hw/display/virtio-gpu-virgl.c
+++ b/hw/display/virtio-gpu-virgl.c
@@ -892,6 +892,7 @@ void virtio_gpu_virgl_process_cmd(VirtIOGPU *g,
struct virtio_gpu_ctrl_command *cmd)
{
bool cmd_suspended = false;
+ int ret;
VIRTIO_GPU_FILL_CMD(cmd->cmd_hdr);
@@ -990,7 +991,12 @@ void virtio_gpu_virgl_process_cmd(VirtIOGPU *g,
}
trace_virtio_gpu_fence_ctrl(cmd->cmd_hdr.fence_id, cmd->cmd_hdr.type);
- virgl_renderer_create_fence(cmd->cmd_hdr.fence_id, cmd->cmd_hdr.type);
+
+ ret = virgl_renderer_create_fence(cmd->cmd_hdr.fence_id, 0);
+ if (ret)
+ qemu_log_mask(LOG_GUEST_ERROR,
+ "%s: virgl_renderer_create_fence error: %s",
+ __func__, strerror(-ret));
}
static void virgl_write_fence(void *opaque, uint32_t fence)
--
2.46.0
- [PATCH v1 0/6] Support virtio-gpu DRM native context, Dmitry Osipenko, 2024/10/06
- [PATCH v1 1/6] ui/sdl2: Restore original context after new context creation, Dmitry Osipenko, 2024/10/06
- [PATCH v1 2/6] ui/sdl2: Implement dpy dmabuf functions, Dmitry Osipenko, 2024/10/06
- [PATCH v1 3/6] linux-headers: Update to Linux v6.12-rc1, Dmitry Osipenko, 2024/10/06
- [PATCH v1 4/6] virtio-gpu: Handle virgl fence creation errors,
Dmitry Osipenko <=
- [PATCH v1 5/6] virtio-gpu: Support asynchronous fencing, Dmitry Osipenko, 2024/10/06
- [PATCH v1 6/6] virtio-gpu: Support DRM native context, Dmitry Osipenko, 2024/10/06
- Re: [PATCH v1 0/6] Support virtio-gpu DRM native context, Akihiko Odaki, 2024/10/07