vga: fixes for 4.0 (ati trace, virtio-gpu reset).
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAABAgAGBQJcj5xiAAoJEEy22O7T6HE4TRoQAKcqkM6v/fBbROlfEyEFEoW3 FEMdmUWxYFtLgdL8hjjnkoODYaXBbjMyxgf719ITIn38fGeqfuTD8WLwJTnf5047 hAEXiVJeWdP3+FSonenhcbK34F3VX79wmUrj8zd4ScWEvaTtB4WdbfdnwjMa21FV 52I6tKRkarnEpVltMgA6wdanQk5YgVWaNJndCkVx/kYc07j3Atg5Z6gEp0zVWLeh 7wh0qsscYmBrgguwLZvua/JncRATTX0LMdMOY8Ef3MFwIX6ZFctD/M+v9a/q36ql 6GYNNRGFnA349zAQcqTJsPXAOs78gBo6IFLQhNRqebwy/Bdu9SiK2sPzTPClpgzJ Tjq2hkcgkGNhVYEdyhjVPyrTxelKA7+hhbqoNkvcHX3pG65rRADIsObgRi7R7io8 W8bFPJe0r/PpENyH9diwsx8pFMj1IuTaKjhju5kwr3Jl2qLU5QIUNxzWU5nmVUC8 54LqvQPKP1C752041pbXcbaSzRP4Dj2WBmo2zTagsrDaL1q4C3KMpJxei2dnD+6O i12TvVg3vRJoT9kJkq2GIqGBNoN3Dz211b5iyKQ9sPMyeouvTuvsqhMIYw1Md8FU g/WrUVeNF9GQYbYOODV1IsEgokui8Udbwln5KP53Dp93mwVbDHxunKd0nQMqMKsd 60+Q3x/fLAUly3y0oNlH =n4eo -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/kraxel/tags/vga-20190318-pull-request' into staging vga: fixes for 4.0 (ati trace, virtio-gpu reset). # gpg: Signature made Mon 18 Mar 2019 13:25:54 GMT # gpg: using RSA key 4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full] # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" [full] # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full] # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/vga-20190318-pull-request: virtio-gpu: clear command and fence queues on reset virtio-gpu: delay virglrenderer reset when blocked. ati-vga: fix tracing Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
e5b670c9f8
@ -140,5 +140,5 @@ sii9022_write_reg(uint8_t addr, uint8_t val) "addr 0x%02x, val 0x%02x"
|
||||
sii9022_switch_mode(const char *mode) "mode: %s"
|
||||
|
||||
# hw/display/ati*.c
|
||||
ati_mm_read(unsigned int size, uint64_t addr, const char *name, uint64_t val) "%u 0x%"HWADDR_PRIx " %s -> 0x%"PRIx64
|
||||
ati_mm_write(unsigned int size, uint64_t addr, const char *name, uint64_t val) "%u 0x%"HWADDR_PRIx " %s <- 0x%"PRIx64
|
||||
ati_mm_read(unsigned int size, uint64_t addr, const char *name, uint64_t val) "%u 0x%"PRIx64 " %s -> 0x%"PRIx64
|
||||
ati_mm_write(unsigned int size, uint64_t addr, const char *name, uint64_t val) "%u 0x%"PRIx64 " %s <- 0x%"PRIx64
|
||||
|
@ -1084,6 +1084,12 @@ static void virtio_gpu_gl_block(void *opaque, bool block)
|
||||
assert(g->renderer_blocked >= 0);
|
||||
|
||||
if (g->renderer_blocked == 0) {
|
||||
#ifdef CONFIG_VIRGL
|
||||
if (g->renderer_reset) {
|
||||
g->renderer_reset = false;
|
||||
virtio_gpu_virgl_reset(g);
|
||||
}
|
||||
#endif
|
||||
virtio_gpu_process_cmdq(g);
|
||||
}
|
||||
}
|
||||
@ -1350,6 +1356,7 @@ static void virtio_gpu_reset(VirtIODevice *vdev)
|
||||
{
|
||||
VirtIOGPU *g = VIRTIO_GPU(vdev);
|
||||
struct virtio_gpu_simple_resource *res, *tmp;
|
||||
struct virtio_gpu_ctrl_command *cmd;
|
||||
int i;
|
||||
|
||||
g->enable = 0;
|
||||
@ -1366,9 +1373,26 @@ static void virtio_gpu_reset(VirtIODevice *vdev)
|
||||
g->scanout[i].ds = NULL;
|
||||
}
|
||||
|
||||
while (!QTAILQ_EMPTY(&g->cmdq)) {
|
||||
cmd = QTAILQ_FIRST(&g->cmdq);
|
||||
QTAILQ_REMOVE(&g->cmdq, cmd, next);
|
||||
g_free(cmd);
|
||||
}
|
||||
|
||||
while (!QTAILQ_EMPTY(&g->fenceq)) {
|
||||
cmd = QTAILQ_FIRST(&g->fenceq);
|
||||
QTAILQ_REMOVE(&g->fenceq, cmd, next);
|
||||
g->inflight--;
|
||||
g_free(cmd);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_VIRGL
|
||||
if (g->use_virgl_renderer) {
|
||||
virtio_gpu_virgl_reset(g);
|
||||
if (g->renderer_blocked) {
|
||||
g->renderer_reset = true;
|
||||
} else {
|
||||
virtio_gpu_virgl_reset(g);
|
||||
}
|
||||
g->use_virgl_renderer = 0;
|
||||
}
|
||||
#endif
|
||||
|
@ -113,6 +113,7 @@ typedef struct VirtIOGPU {
|
||||
bool use_virgl_renderer;
|
||||
bool renderer_inited;
|
||||
int renderer_blocked;
|
||||
bool renderer_reset;
|
||||
QEMUTimer *fence_poll;
|
||||
QEMUTimer *print_stats;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user