mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-01 23:03:54 -06:00
virtio-gpu: add support to enable/disable command processing
So we can stop rendering for a while in case we have to. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
parent
3eb769fd1c
commit
0c55a1cfd3
3 changed files with 8 additions and 2 deletions
|
@ -755,7 +755,7 @@ static void virtio_gpu_handle_cursor_cb(VirtIODevice *vdev, VirtQueue *vq)
|
|||
qemu_bh_schedule(g->cursor_bh);
|
||||
}
|
||||
|
||||
static void virtio_gpu_process_cmdq(VirtIOGPU *g)
|
||||
void virtio_gpu_process_cmdq(VirtIOGPU *g)
|
||||
{
|
||||
struct virtio_gpu_ctrl_command *cmd;
|
||||
|
||||
|
@ -765,6 +765,9 @@ static void virtio_gpu_process_cmdq(VirtIOGPU *g)
|
|||
/* process command */
|
||||
VIRGL(g, virtio_gpu_virgl_process_cmd, virtio_gpu_simple_process_cmd,
|
||||
g, cmd);
|
||||
if (cmd->waiting) {
|
||||
break;
|
||||
}
|
||||
QTAILQ_REMOVE(&g->cmdq, cmd, next);
|
||||
if (virtio_gpu_stats_enabled(g->conf)) {
|
||||
g->stats.requests++;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue