summary refs log tree commit diff stats
path: root/gitlab/issues/target_missing/host_missing/accel_missing/2303.toml
blob: a1226b7caedb4d2c9a80490cbdf83388f573a28e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
id = 2303
title = "Multiple displays configuration supports"
state = "opened"
created_at = "2024-04-23T07:59:23.936Z"
closed_at = "n/a"
labels = ["GUI"]
url = "https://gitlab.com/qemu-project/qemu/-/issues/2303"
host-os = "n/a"
host-arch = "n/a"
qemu-version = "n/a"
guest-os = "n/a"
guest-arch = "n/a"
description = "n/a"
reproduce = "n/a"
additional = """The following patch is a quick "hack" to make it work

```patch

From 18ad5058a18fa9f6db2c0c3058e25989908d95bb Mon Sep 17 00:00:00 2001
From: Sergio Lopez <slp@redhat.com>
Date: Fri, 23 Jun 2023 13:15:15 +0200
Subject: [PATCH 6/8] HACK: Set static resolutions for the VM

---
 hw/display/virtio-gpu-base.c | 10 +++++++++-
 ui/gtk.c                     |  6 ++++--
 2 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/hw/display/virtio-gpu-base.c b/hw/display/virtio-gpu-base.c
index a29f191aa8..b1ccfa17b7 100644
--- a/hw/display/virtio-gpu-base.c
+++ b/hw/display/virtio-gpu-base.c
@@ -47,6 +47,7 @@ virtio_gpu_base_fill_display_info(VirtIOGPUBase *g,
             dpy_info->pmodes[i].enabled = 1;
             dpy_info->pmodes[i].r.width = cpu_to_le32(g->req_state[i].width);
             dpy_info->pmodes[i].r.height = cpu_to_le32(g->req_state[i].height);
+            fprintf(stderr, "display %d: %dx%d\\n", i, dpy_info->pmodes[i].r.width, dpy_info->pmodes[i].r.height);
         }
     }
 }
@@ -63,14 +64,17 @@ static void virtio_gpu_text_update(void *opaque, console_ch_t *chardata)
 {
 }
 
+#if 0
 static void virtio_gpu_notify_event(VirtIOGPUBase *g, uint32_t event_type)
 {
     g->virtio_config.events_read |= event_type;
     virtio_notify_config(&g->parent_obj);
 }
+#endif
 
 static void virtio_gpu_ui_info(void *opaque, uint32_t idx, QemuUIInfo *info)
 {
+#if 0
     VirtIOGPUBase *g = opaque;
 
     if (idx >= g->conf.max_outputs) {
@@ -94,6 +98,7 @@ static void virtio_gpu_ui_info(void *opaque, uint32_t idx, QemuUIInfo *info)
     /* send event to guest */
     virtio_gpu_notify_event(g, VIRTIO_GPU_EVENT_DISPLAY);
     return;
+#endif
 }
 
 static void
@@ -186,11 +191,14 @@ virtio_gpu_base_device_realize(DeviceState *qdev,
         virtio_add_queue(vdev, 16, cursor_cb);
     }
 
-    g->enabled_output_bitmask = 1;
+    g->enabled_output_bitmask = 3;
 
     g->req_state[0].width = g->conf.xres;
     g->req_state[0].height = g->conf.yres;
 
+    g->req_state[1].width = 800;
+    g->req_state[1].height = 600;
+
     g->hw_ops = &virtio_gpu_ops;
     for (i = 0; i < g->conf.max_outputs; i++) {
         g->scanout[i].con =
```"""